Fix the remaining lint errors.

This commit is contained in:
Ian Gulliver
2015-10-16 16:23:29 +02:00
parent f77007e047
commit cec8a6c9d3
2 changed files with 6 additions and 4 deletions

View File

@@ -191,7 +191,7 @@ Cosmopolite.typeMessage;
/**
* @typedef {{command: string,
arguments: Object,
onSuccess: (function(Object)|null)}}
onSuccess: (?function(Object))}}
* @private
*/
Cosmopolite.typeRPC_;
@@ -540,7 +540,8 @@ Cosmopolite.prototype.pin = function(subject, message) {
// Ugly hack, but we need this to promise to resolve before the callback
// fires. This is the equivalent of sched_yield(), and probably about as
// reliable.
window.setTimeout(this.onPin_.bind(this, Object.create(args)), 0);
var msg = /** @type {Cosmopolite.typeMessage} */ (Object.create(args));
window.setTimeout(this.onPin_.bind(this, msg), 0);
return;
}
@@ -566,7 +567,8 @@ Cosmopolite.prototype.unpin = function(id) {
if (pin['subject']['local']) {
resolve();
window.setTimeout(this.onUnpin_.bind(this, Object.create(pin)), 0);
var msg = /** @type {Cosmopolite.typeMessage} */ (Object.create(pin));
window.setTimeout(this.onUnpin_.bind(this, msg), 0);
return;
}

View File

@@ -6,7 +6,7 @@ curl \
--data output_format=json \
--data output_info=errors \
--data output_info=warnings \
--data language=ECMASCRIPT5 \
--data language=ECMASCRIPT6 \
--data warning_level=verbose \
--data-urlencode "js_code@cosmopolite.js" \
http://closure-compiler.appspot.com/compile