It's easier to skip the check in the two places that we need to, and include it by default everywhere else.
17 lines
544 B
Ruby
17 lines
544 B
Ruby
module Api
|
|
class VersionsController < ApiController
|
|
skip_before_action :check_api_readable
|
|
authorize_resource :class => false
|
|
|
|
before_action :set_request_formats
|
|
around_action :api_call_handle_error, :api_call_timeout
|
|
|
|
# Show the list of available API versions. This will replace the global
|
|
# unversioned capabilities call in due course.
|
|
# Currently we only support deploying one version at a time, but this will
|
|
# hopefully change soon.
|
|
def show
|
|
@versions = [Settings.api_version]
|
|
end
|
|
end
|
|
end
|