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
Parse.Cloud.afterSave("Upload", function(req) { | |
if(req.user) { | |
if(req.object.has('type') && req.object.has('file')) { | |
var type = req.object.get('type'); | |
if(type === 'avatar') { | |
console.log("Saving file..." + req.user.id); |
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
// By Jamie Chapman, @chappers57 | |
// License: open, do as you wish, just don't blame me if stuff breaks ;-) | |
public class ParseProxyObject implements Serializable { | |
private static final long serialVersionUID = 1L; | |
private HashMap<String, Object> values = new HashMap<String, Object>(); | |
public HashMap<String, Object> getValues() { | |
return values; |