Skip to content

Commit 900c22b

Browse files
author
Marcin Olichwirowicz
committed
removing redundant condition
1 parent c23f5d9 commit 900c22b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/grape/middleware/versioner/header.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def before
2626
accept = env['HTTP_ACCEPT'] || ""
2727

2828
if options[:version_options] && options[:version_options].keys.include?(:strict) && options[:version_options][:strict]
29-
if (incorrect_header?(accept)) && options[:versions] && options[:version_options][:using] == :header
29+
if (incorrect_header?(accept)) && options[:version_options][:using] == :header
3030
throw :error, :status => 404, :headers => {'X-Cascade' => 'pass'}, :message => "404 API Version Not Found"
3131
end
3232
end

0 commit comments

Comments
 (0)