diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 42badfe..d834b7e 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -1,9 +1,6 @@ class ApplicationController < ActionController::Base - # Prevent CSRF attacks by raising an exception. - # For APIs, you may want to use :null_session instead. protect_from_forgery with: :exception require 'nokogiri' require 'open-uri' - end diff --git a/app/controllers/welcome_controller.rb b/app/controllers/welcome_controller.rb index e2e98e6..f1543c8 100644 --- a/app/controllers/welcome_controller.rb +++ b/app/controllers/welcome_controller.rb @@ -1,5 +1,4 @@ class WelcomeController < ApplicationController - def index @group = Welcome.new.sort end diff --git a/app/models/welcome.rb b/app/models/welcome.rb index e6d19b6..ca0640c 100644 --- a/app/models/welcome.rb +++ b/app/models/welcome.rb @@ -1,5 +1,4 @@ class Welcome - def initialize @urls =["https://github.com/bad6e", "https://github.com/roseak", @@ -43,4 +42,4 @@ def get_count def open_url(url) Nokogiri::HTML(open(url)) end -end \ No newline at end of file +end diff --git a/app/views/welcome/index.html.erb b/app/views/welcome/index.html.erb index a58f4c3..15b45fe 100644 --- a/app/views/welcome/index.html.erb +++ b/app/views/welcome/index.html.erb @@ -1,92 +1,90 @@ + - + + + + + - - - - - + 1507 Git Commit Race - 1507 Git Commit Race + + - - + + - - + + + - - - + - + - - - - + + - -
-
-
-

1507 Git Commit Race

-

Compete with the best - who will have the most commits when Turing is over?

+ +
+
+
+

1507 Git Commit Race

+

Compete with the best - who will have the most commits when Turing is over?

+
-
-
-
-
-

Leaderboard

- - - - - - +
+
+
+

Leaderboard

+
PlaceName
+ + + + <% n = 0 %> <% @group.each do |css| %> - - - - <% end %> -
PlaceName
<%= n = n + 1 %><%= css.join("- ") %> commits
+ + + + + <% end %> +
<%= n = n + 1 %><%= css.join("- ") %> commits
+ - - - +