public static void saveAvatar(String path) throws IOException, AVException { AVUser user = AVUser.getCurrentUser(); final AVFile file = AVFile.withAbsoluteLocalPath(user.getUsername(), path); file.save(); user.put(User.AVATAR, file); user.save(); user.fetch(); }