Skip to content

Instantly share code, notes, and snippets.

@opichals
Created March 13, 2014 12:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save opichals/9527732 to your computer and use it in GitHub Desktop.
Save opichals/9527732 to your computer and use it in GitHub Desktop.
Em.Logger...
+ Em.Logger.assert = function myAssert(test, message) {
+ if (!test) {
+ try {
+ throw new Error(message);
+ } catch(e) {
+ console.log('ASSERT LOG: '+e.message+e.trace);
+ } finally {
+ console.trace('ASSERT: '+message);
+ console.assert(test, 'ASSERT: '+message);
+ }
+ }
+ };
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment