summaryrefslogtreecommitdiff
path: root/app/models/project_ci_cd_setting.rb
diff options
context:
space:
mode:
authorClement Ho <ClemMakesApps@gmail.com>2018-04-25 10:51:53 -0500
committerClement Ho <ClemMakesApps@gmail.com>2018-04-25 10:51:53 -0500
commit56982fcf24ba4290dcca6b8c4e852d716b179748 (patch)
treeeb4c8883d41b21212468a6f8f07990b61d7181d8 /app/models/project_ci_cd_setting.rb
parent80766821b24cc13a6ce054f5b0c996bebccc4121 (diff)
parentc5f6c811eec6bca7952f84af9e30f3fafb848352 (diff)
downloadgitlab-ce-56982fcf24ba4290dcca6b8c4e852d716b179748.tar.gz
Merge branch 'master' into bootstrap4
Diffstat (limited to 'app/models/project_ci_cd_setting.rb')
-rw-r--r--app/models/project_ci_cd_setting.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/app/models/project_ci_cd_setting.rb b/app/models/project_ci_cd_setting.rb
new file mode 100644
index 00000000000..9f10a93148c
--- /dev/null
+++ b/app/models/project_ci_cd_setting.rb
@@ -0,0 +1,16 @@
+class ProjectCiCdSetting < ActiveRecord::Base
+ belongs_to :project
+
+ # The version of the schema that first introduced this model/table.
+ MINIMUM_SCHEMA_VERSION = 20180403035759
+
+ def self.available?
+ @available ||=
+ ActiveRecord::Migrator.current_version >= MINIMUM_SCHEMA_VERSION
+ end
+
+ def self.reset_column_information
+ @available = nil
+ super
+ end
+end