{"size": 340, "ext": "js", "max_stars_repo_path": "src/views/7gui/db/UpdateUser.js", "max_stars_repo_name": "rodrigokestler/hugo-7gui", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/views/7gui/db/UpdateUser.js", "max_issues_repo_name": "rodrigokestler/hugo-7gui", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/views/7gui/db/UpdateUser.js", "max_forks_repo_name": "rodrigokestler/hugo-7gui", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 21.25, "max_line_length": 40, "alphanum_fraction": 0.5852941176}
import PouchDB from 'pouchdb';

function UpdateUser(user) {
    
    let db = new PouchDB('crud');
    db.get(user._id).then(function(doc){
      
      doc.name = user.name;
      doc.surname = user.surname;
      doc.label   = user.label;
      doc.value = user.value;
      
      return db.put(doc);
    });
}
export default UpdateUser;