{"size": 317, "ext": "js", "max_stars_repo_path": "middlewares/auth/admin-auth.mdw.js", "max_stars_repo_name": "TrungTho/HCMUS_ChildrenHealthMonitoring_Server", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "middlewares/auth/admin-auth.mdw.js", "max_issues_repo_name": "TrungTho/HCMUS_ChildrenHealthMonitoring_Server", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "middlewares/auth/admin-auth.mdw.js", "max_forks_repo_name": "TrungTho/HCMUS_ChildrenHealthMonitoring_Server", "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": 24.3846153846, "max_line_length": 75, "alphanum_fraction": 0.6561514196}
//middleware function to check right of client to access profile

module.exports = function adminAuth(req, res, next) {
  if (req.user.username === process.env.ADMIN_USERNAME) {
  } else {
    return res
      .status(403)
      .send({ success: false, err_message: "access denied!! wrong user" });
  }

  next();
};
