mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2025-01-11 10:39:56 -05:00
Report missing storage module as an error
This commit is contained in:
parent
3d7f1187e5
commit
10cb97c52e
2 changed files with 4 additions and 4 deletions
|
@ -162,11 +162,11 @@ var parseScratchObject = function (object, runtime, topLevel) {
|
|||
*/
|
||||
var loadCostume = function (md5ext, costume, runtime) {
|
||||
if (!runtime.storage) {
|
||||
log('No storage module present; cannot load costume asset: ', md5ext);
|
||||
log.error('No storage module present; cannot load costume asset: ', md5ext);
|
||||
return null;
|
||||
}
|
||||
if (!runtime.renderer) {
|
||||
log('No rendering module present; cannot load costume asset: ', md5ext);
|
||||
log.error('No rendering module present; cannot load costume asset: ', md5ext);
|
||||
return null;
|
||||
}
|
||||
|
||||
|
@ -223,7 +223,7 @@ var loadCostume = function (md5ext, costume, runtime) {
|
|||
*/
|
||||
var loadSound = function (sound, runtime) {
|
||||
if (!runtime.storage) {
|
||||
log('No storage module present; cannot load sound asset: ', sound.md5);
|
||||
log.error('No storage module present; cannot load sound asset: ', sound.md5);
|
||||
return;
|
||||
}
|
||||
var idParts = sound.md5.split('.');
|
||||
|
|
|
@ -163,7 +163,7 @@ VirtualMachine.prototype.loadProject = function (json) {
|
|||
*/
|
||||
VirtualMachine.prototype.downloadProjectId = function (id) {
|
||||
if (!this.runtime.storage) {
|
||||
log('No storage module present; cannot load project: ', id);
|
||||
log.error('No storage module present; cannot load project: ', id);
|
||||
return;
|
||||
}
|
||||
var vm = this;
|
||||
|
|
Loading…
Reference in a new issue