소스 검색

Fixed bug that didn't test listener type.

dev-tmpl
Bryan Miller 7 년 전
부모
커밋
6919de7f05
1개의 변경된 파일2개의 추가작업 그리고 0개의 파일을 삭제
  1. +2
    -0
      app/js/EventCaller.js

+ 2
- 0
app/js/EventCaller.js 파일 보기

* @returns {this} * @returns {this}
*/ */
listen(eventName, callback, owner=null, once=false){ listen(eventName, callback, owner=null, once=false){
if (typeof(callback) !== 'function')
throw new TypeError("Expected callback argument to be a function or class method.");
try{ try{
if (!this.is_listening(eventName, callback, owner)){ if (!this.is_listening(eventName, callback, owner)){
if (!this.__listeners.hasOwnProperty(eventName)){ if (!this.__listeners.hasOwnProperty(eventName)){

Loading…
취소
저장