Skip to content

Commit

Permalink
Change some console.warn to Debug.warn (#4194)
Browse files Browse the repository at this point in the history
* prevent some console.warn not in debug build

* fix
  • Loading branch information
Maksims authored Apr 12, 2022
1 parent 3b32c99 commit aa3f934
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/framework/components/element/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -770,7 +770,7 @@ class ElementComponent extends Component {
}
} else {
if (this._useInput === true) {
console.warn('Elements will not get any input events because this.system.app.elementInput is not created');
Debug.warn('Elements will not get any input events because this.system.app.elementInput is not created');
}
}

Expand Down
4 changes: 3 additions & 1 deletion src/sound/manager.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { Debug } from '../core/debug.js';

import { platform } from '../core/platform.js';
import { EventHandler } from '../core/event-handler.js';

Expand Down Expand Up @@ -62,7 +64,7 @@ class SoundManager extends EventHandler {
if (hasAudioContext() || this._forceWebAudioApi) {
this._addAudioContextUserInteractionListeners();
} else {
console.warn('No support for 3D audio found');
Debug.warn('No support for 3D audio found');
}

this.listener = new Listener(this);
Expand Down

0 comments on commit aa3f934

Please sign in to comment.