I'm normally using async/await and syntax-async-functions. But today when I upgraded to version 6.16.0, then my function async/await got error like below. I dont use for-of-await. Now dont know how to config label to write async/await normally?
Tks.
Error: /usr/src/server.js: You gave us a visitor for the node type "ForAwaitStatement" but it's not a valid type
Related
I’ve got a really weird error when trying to run an app built with NativeScript and Angular 2. Here’s the error:
CONSOLE ERROR file:///app/tns_modules/nativescript-angular/zone.js/dist/zone-nativescript.js:342:26:
Unhandled Promise rejection: No map found ; Zone: angular ; Task: Promise.then ; Value: No map found undefined
CONSOLE ERROR file:///app/tns_modules/nativescript-angular/zone.js/dist/zone-nativescript.js:344:22:
Error: Uncaught (in promise): No map found
The error occurs when the app starts up. I’m using nativescript-angular version 1.1.2 and I’m including zone.js version 0.6.21 in my devDependencies. Here’s my full package.json: https://github.com/tjvantoll/nativescript-photos-near-me/blob/6a201b05e91687618670a79e0a56ababc71572d7/package.json.
Any idea what might be up? I’m not actually using zones explicitly in my app, so I’m very curious why I’m getting this app here but not in new NativeScript Angular apps I start from scratch.
Any help would be appreciated.
So as soon as I posted this I figured this out. The problem was an innocuous looking call to the Mapbox plugin’s unhide() method.
I assumed “map” was referring to some RxJS or Array value, when it was actually referring to an actual map. Who knew?
I am using the following function to get the version of Datatable I am using :
alert($.fn.DataTable.versionCheck());
But I am getting error as :
$.fn.DataTable.versionCheck is not a function
What is wrong in my code?
The code you are using is designed to check the current version number against the provided version number, for example:
$.fn.dataTable.versionCheck('1.9.2')
will check if the version number you are using matches 1.9.2. You are not providing a parameter to the function.
I believe the $.fn.dataTable.versionCheck() function was added in version 1.10, so if you are running an older version that may explain why you are getting your error message.
You can use the following code to get the version number:
$(document).ready(function(){
$('#myTable').DataTable();
var versionNo = $.fn.dataTable.version;
alert(versionNo);
});
Please see demo here. Hope it helps.
I know this is old, but you can just go to your browser console and run:
$.fn.DataTable.version
I have just installed the Parse framework.
However I get strange errors :
'PFPush' does not have a member named 'sendPushInBackground'
However this function IS in the header of Parse framework.
It seems that it doesn't recognize the function whenever it uses a BTTask. So I tried to add Bolts framework and FacebookSDK, only Bolt, only FacebookSDK but none of these helped me.
Do you have any idea ?
Thanks
I'm trying to port the Twitter Notifier extension to FF.
I'm not too familiar with JavaScript so I just used extension factory to convert it to FF.
Unfortunately it is not working; I don't get any HTML5 desktop notifications.
I've looked at the code a bit and I think the problem is with twitter.js which should be found in the path 'resources\extension-data\js'.
http://pastebin.com/C0NqU4Ur
First I've changed
twitter.messagesDB = window.webkitIndexedDB.open("messagesDB");
to
twitter.messagesDB = window.mozIndexedDB.open("messagesDB");
but it still is not working.
The error console also doesn't show any error.
When I put a console.log command to the twitter.messagesDB.onsuccess function nothing is being outputted to the error console.
Also no output when I create an onerror function.
So I though to surround the functions with a try and catch clause but no error is being thrown.
So I tried to put twitter.messagesDB = twitter.messagesDB.result; out of the function and the following error shows up in the error console:
Error: uncaught exception: [Exception... "A mutation operation was attempted on a database that did not allow mutations." code: "6" nsresult: "0x80660006 (NS_ERROR_DOM_INDEXEDDB_NOT_ALLOWED_ERR)" location: "chrome-extension://gjlehiopfilnaggndcmbhphaglkbkekf/js/twitter.js Line: 28"]
What does that mean?
How can I make it work in Firefox?
Thanks in advance!
Edit: I'm using Firefox 12 on Windows
This is due to an incompatibility between the Firefox implementation of IndexedDB, which supports the latest IndedexDB protocol published December 2011, and the Chrome implementation, which supports the version previous to that.
The breaking change is how databases are created, where the older (Chrome) implementation uses the setVersion transaction whereas the newer version (FF) uses an onupgradeneeded event and callback.
To see this change, please star this issue.
A society I belong to have a website which someone who left a few years ago set up. It was done using codeigniter (which was probably rather excessive given that the website is pretty simple.)
The server it is hosted on updated Php recently, which resulted in the website completely breaking. It now simply returns a page full of deprecated function error messages like
"A PHP Error was encountered
Severity: 8192
Message: Function set_magic_quotes_runtime() is deprecated
Filename: codeigniter/CodeIgniter.php
Line Number: 60
"
Reading the CodeIgniter documentation it seemed the new version would work fine with the latest PhP installed on the server. I installed a the latest version of CodeIgniter (1.7.2) and copied over the views and database settings. I now get an error message about the image() function being undefined:
"Fatal error: Call to undefined function image() in /public_html/newSystem/application/views/welcome_index.php on line 32"
I tried searching through all the CodeIgniter documentation, and couldn't find any reference to this function.
it is used in the following fasion:
<?=image('welcome_index_splash-text.gif')?>
which led me to believe it was related to the img() function which converts text into an element, but replacing image() with img() gave the same error message. (Well, with img being undefined instead of image)
Since I have never used CodeIgniter before, there is probably a very simple fix, but it doesn't seem readily available from the UsersGuide.
The lesson would be not to use a framework like CodeIgniter when static HTML would have done, but it wasn't my decision to set it up like this in the first place!
Thank you for any help.
Codeigniter has a helper function called img() which returns the HTML code for the image provided as argument. If you get that error you're probably not including the right helper library like this:
$this->load->helper('html');
in your controller.
Reference: http://codeigniter.com/user_guide/helpers/html_helper.html