Skip to content
This repository has been archived by the owner on Apr 21, 2021. It is now read-only.

Commit

Permalink
Add mix format
Browse files Browse the repository at this point in the history
  • Loading branch information
carlogilmar committed Sep 22, 2019
1 parent 522f5f4 commit 371bf3c
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions lib/spawnfest/github/github_engine.ex
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ defmodule GitHubApiEngine do
repo_info = NetworkConsumer.get("#{@api}#{org}/#{repo}", @github_headers)

%GitHubRepository{
fullname: GitHubUtil.set_default_response.(repo_info["full_name"]),
avatar_url: GitHubUtil.set_default_response.(repo_info["owner"]["avatar_url"]),
description: GitHubUtil.set_default_response.(repo_info["description"]),
open_issues: GitHubUtil.set_default_response.(repo_info["open_issues"]),
forks: GitHubUtil.set_default_response.(repo_info["forks"]),
language: GitHubUtil.set_default_response.(repo_info["language"]),
default_branch: GitHubUtil.set_default_response.(repo_info["default_branch"])
fullname: GitHubUtil.set_default_response().(repo_info["full_name"]),
avatar_url: GitHubUtil.set_default_response().(repo_info["owner"]["avatar_url"]),
description: GitHubUtil.set_default_response().(repo_info["description"]),
open_issues: GitHubUtil.set_default_response().(repo_info["open_issues"]),
forks: GitHubUtil.set_default_response().(repo_info["forks"]),
language: GitHubUtil.set_default_response().(repo_info["language"]),
default_branch: GitHubUtil.set_default_response().(repo_info["default_branch"])
}
end
end
Expand All @@ -31,10 +31,10 @@ defmodule GitHubApiEngine do
defp get_issues(repo_info) do
for issue <- repo_info do
%GitHubIssue{
url: GitHubUtil.set_default_response.(issue["html_url"]),
title: GitHubUtil.set_default_response.(issue["title"]),
state: GitHubUtil.set_default_response.(issue["state"]),
date_created: GitHubUtil.set_default_response.(issue["created_at"])
url: GitHubUtil.set_default_response().(issue["html_url"]),
title: GitHubUtil.set_default_response().(issue["title"]),
state: GitHubUtil.set_default_response().(issue["state"]),
date_created: GitHubUtil.set_default_response().(issue["created_at"])
}
end
end
Expand All @@ -49,11 +49,11 @@ defmodule GitHubApiEngine do
defp get_pull_requests(pulls) do
for pull <- pulls do
%GitHubPR{
number: GitHubUtil.set_default_response.(pull["number"]),
title: GitHubUtil.set_default_response.(pull["title"]),
state: GitHubUtil.set_default_response.(pull["state"]),
url: GitHubUtil.set_default_response.(pull["html_url"]),
author: GitHubUtil.set_default_response.(pull["author_association"])
number: GitHubUtil.set_default_response().(pull["number"]),
title: GitHubUtil.set_default_response().(pull["title"]),
state: GitHubUtil.set_default_response().(pull["state"]),
url: GitHubUtil.set_default_response().(pull["html_url"]),
author: GitHubUtil.set_default_response().(pull["author_association"])
}
end
end
Expand All @@ -68,9 +68,9 @@ defmodule GitHubApiEngine do
def get_contributors(repo_info) do
for contributor <- repo_info do
%GitHubContributor{
avatar_url: GitHubUtil.set_default_response.(contributor["avatar_url"]),
username: GitHubUtil.set_default_response.(contributor["login"]),
contributions: GitHubUtil.set_default_response.(contributor["contributions"])
avatar_url: GitHubUtil.set_default_response().(contributor["avatar_url"]),
username: GitHubUtil.set_default_response().(contributor["login"]),
contributions: GitHubUtil.set_default_response().(contributor["contributions"])
}
end
end
Expand Down

0 comments on commit 371bf3c

Please sign in to comment.