Skip to content

Commit 9447781

Browse files
committed
changed validation-ish sounding correctly_vendored variable to is_vendored_match
1 parent cba257e commit 9447781

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/grape/middleware/versioner/header.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ def before
3636

3737
subtype.scan(/vnd\.(.+)?-(.+)?\+(.*)?/) do |vendor, version, format|
3838
is_vendored = options[:version_options] && options[:version_options][:vendor]
39-
correctly_vendored = is_vendored ? options[:version_options][:vendor] == vendor : true
39+
is_vendored_match = is_vendored ? options[:version_options][:vendor] == vendor : true
4040

41-
if (options[:versions] && !options[:versions].include?(version)) || !correctly_vendored
41+
if (options[:versions] && !options[:versions].include?(version)) || !is_vendored_match
4242
throw :error, :status => 404, :headers => {'X-Cascade' => 'pass'}, :message => "404 API Version Not Found"
4343
end
4444

0 commit comments

Comments
 (0)