{"size": 444, "ext": "js", "max_stars_repo_path": "lib/trail.js", "max_stars_repo_name": "brody-rebne/city-explorer", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "lib/trail.js", "max_issues_repo_name": "brody-rebne/city-explorer", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "lib/trail.js", "max_forks_repo_name": "brody-rebne/city-explorer", "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.6666666667, "max_line_length": 51, "alphanum_fraction": 0.7117117117}
'use strict';

function Trail(obj) {
  this.name = obj.name;
  this.location = obj.location;
  this.length = obj.length;
  this.stars = obj.stars;
  this.star_votes = obj.starVotes;
  this.summary = obj.summary;
  this.trail_url = obj.url;
  this.conditions = obj.conditionStatus;
  let splitDateTime = obj.conditionDate.split(' ');
  this.condition_date = splitDateTime[0];
  this.condition_time = splitDateTime[1];
}

module.exports = Trail;
