mirror of
https://github.com/evennia/evennia.git
synced 2026-03-16 21:06:30 +01:00
Update evennia.js
Fix for misplaced parens-- previous code checked 'is the output of `typeof(listener === 'function')` truthy', which is equivalent of `typeof(boolean)` which is always true.
This commit is contained in:
parent
0c1d0b172b
commit
819097fdde
1 changed files with 1 additions and 1 deletions
|
|
@ -195,7 +195,7 @@ An "emitter" object must have a function
|
|||
// to listen to cmdname events.
|
||||
//
|
||||
var on = function (cmdname, listener) {
|
||||
if (typeof(listener === 'function')) {
|
||||
if (typeof(listener) === 'function') {
|
||||
listeners[cmdname] = listener;
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue