Skip to content

Commit

Permalink
refactoring; better layout
Browse files Browse the repository at this point in the history
  • Loading branch information
JonJagger committed Jan 7, 2017
1 parent 2d1ae5c commit 24972ff
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 deletions.
10 changes: 3 additions & 7 deletions app/lib/differ_service.rb
@@ -1,7 +1,7 @@
require 'net/http'
require 'json'
require_relative 'http_service'
require_relative '../../lib/nearest_ancestors'
require 'net/http'
require 'json'

class DifferService

Expand All @@ -14,11 +14,7 @@ def initialize(parent)
def diff(kata_id, avatar_name, was_tag, now_tag)
# See https://github.com/cyber-dojo/commander
# and its docker-compose.yml
args = []
args << kata_id
args << avatar_name
args << was_tag
args << now_tag
args = [kata_id, avatar_name, was_tag, now_tag]
visible_files = storer.tags_visible_files(*args)
was_files = visible_files['was_tag']
now_files = visible_files['now_tag']
Expand Down
8 changes: 1 addition & 7 deletions app/lib/runner_service.rb
Expand Up @@ -28,13 +28,7 @@ def new_avatar(image_name, kata_id, avatar_name, starting_files)
end

def run(image_name, kata_id, avatar_name, deleted_filenames, changed_files, max_seconds)
args = []
args << image_name
args << kata_id
args << avatar_name
args << deleted_filenames
args << changed_files
args << max_seconds
args = [image_name, kata_id, avatar_name, deleted_filenames, changed_files, max_seconds]
sss = post(__method__, *args)
[sss['stdout'], sss['stderr'], sss['status']]
end
Expand Down

0 comments on commit 24972ff

Please sign in to comment.