This repository has been archived on 2024-06-09. You can view files and clone it, but cannot push or open issues/pull-requests.
2021-04-03 14:12:30 +02:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
class Admin::SystemCheck::DatabaseSchemaCheck < Admin::SystemCheck::BaseCheck
|
2022-07-05 02:41:40 +02:00
|
|
|
def skip?
|
|
|
|
!current_user.can?(:view_devops)
|
|
|
|
end
|
|
|
|
|
2021-04-03 14:12:30 +02:00
|
|
|
def pass?
|
|
|
|
!ActiveRecord::Base.connection.migration_context.needs_migration?
|
|
|
|
end
|
|
|
|
|
|
|
|
def message
|
|
|
|
Admin::SystemCheck::Message.new(:database_schema_check)
|
|
|
|
end
|
|
|
|
end
|