{"size": 581, "ext": "js", "max_stars_repo_path": "client/src/services/AccountService.js", "max_stars_repo_name": "MikeyZboy/PostBootCampPlanner", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "client/src/services/AccountService.js", "max_issues_repo_name": "MikeyZboy/PostBootCampPlanner", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "client/src/services/AccountService.js", "max_forks_repo_name": "MikeyZboy/PostBootCampPlanner", "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.5185185185, "max_line_length": 63, "alphanum_fraction": 0.6299483649}
import ApiClient from './ApiClient'

export const __GetProfile = async (account_id) => {
  try {
    const res = await ApiClient.get(`/accounts/${account_id}`);
    return res.data;
  } catch (error) {
    throw error;
  }
};

export const __UpdateGoal = async (userData) => {
  const accountId = localStorage.getItem("account_id");
  try {
    const res = await ApiClient.put(
      `/accounts/${accountId}`,
      userData
    );
    return res.data[1].goal;
  } catch (error) {
    throw error;
  }
};

export const __SignOutUser = () => {
  localStorage.clear("account_id");
};