Skip to content

Commit 114bc62

Browse files
committed
Nil platform handler for StaticControllers
1 parent 2cebc66 commit 114bc62

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

app/controllers/static_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,6 @@ def newest_version
3434
protected
3535

3636
def platform
37-
request.user_agent.downcase
37+
request.user_agent.nil? ? nil : request.user_agent.downcase
3838
end
3939
end

features/support/env.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@
4040

4141
Before do
4242
DatabaseCleaner[:mongo_mapper].clean
43-
page.driver.header('User-Agent', "Mac")
4443
end
4544

4645
# You may also want to configure DatabaseCleaner to use different strategies for certain features and scenarios.

0 commit comments

Comments
 (0)