Commit eced61d9 authored by Toon Claes's avatar Toon Claes

Pass the result as a positive bool

parent 5e1d5357
......@@ -5,15 +5,16 @@ module RepositoryCheck
def perform(project_id)
project = Project.find(project_id)
result = check(project)
save_result(project, !check)
save_result(project, result)
end
private
def save_result(project, failure)
def save_result(project, result)
project.update_columns(
last_repository_check_failed: failure,
last_repository_check_failed: !result,
last_repository_check_at: Time.now
)
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment