Created
May 10, 2016 16:06
-
-
Save mytc/859aea8266dd948e91189198a19af964 to your computer and use it in GitHub Desktop.
The method cannot be saved using jagi astronomy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
EditSpace(data){ | |
if(Roles.userIsInRole(this.userId, ['admin'])){ | |
let input = { | |
title : data['title'].trim(), | |
content : data['content'], | |
location : data['location'], | |
tag : data['tag'], | |
col : Number(data['col']), | |
row : Number(data['row']), | |
} | |
let id = data['id']; | |
let space = Spaces.findOne(id); | |
space.set(input); | |
space.save(function(err,id){ | |
if(err){ | |
console.log(err); | |
throw new Meteor.Error('erro-obj', err); | |
}else{ | |
return id; | |
} | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment