Я пытаюсь получить сайт rails и запускать из github, и я сталкиваюсь с этими ошибками:
WARNING: 'task :t, arg, :needs => [deps]' is deprecated. Please use 'task :t, [args] => [deps]' instead.
at /Library/Ruby/Gems/1.8/gems/sunspot_rails-1.2.1/lib/sunspot/rails/tasks.rb:41 rake aborted! /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:15: odd number list for Hash
user_id: current_user.id,
^ /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:15: syntax error, unexpected ':', expecting '}'
user_id: current_user.id,
^ /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:16: syntax error, unexpected ':', expecting '='
page: request.url
^ /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:17: syntax error, unexpected '}', expecting kEND
})
^ /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:20: odd number list for Hash
page: request.url
^ /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:20: syntax error, unexpected ':', expecting '}'
page: request.url
^ /Users/robertgrzesik/Documents/RubyOnRails/IndieOption/app/helpers/advertisements_helper.rb:21: syntax error, unexpected '}', expecting kEND
})
^
для этого кода:
if ad
if current_user
ad.impressions.create({
user_id: current_user.id,
page: request.url
})
else
ad.impressions.create({
page: request.url
})
end
link_to external_redirect_advertisement_url(ad) do
image_tag ad.image.url(format)
end
else
nil
end
end
Любые идеи?