summaryrefslogtreecommitdiff
path: root/app/models/integrations/confluence.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/integrations/confluence.rb')
-rw-r--r--app/models/integrations/confluence.rb15
1 files changed, 1 insertions, 14 deletions
diff --git a/app/models/integrations/confluence.rb b/app/models/integrations/confluence.rb
index 65adce7a8d6..4e1d1993d02 100644
--- a/app/models/integrations/confluence.rb
+++ b/app/models/integrations/confluence.rb
@@ -1,7 +1,7 @@
# frozen_string_literal: true
module Integrations
- class Confluence < Integration
+ class Confluence < BaseThirdPartyWiki
VALID_SCHEME_MATCH = %r{\Ahttps?\Z}.freeze
VALID_HOST_MATCH = %r{\A.+\.atlassian\.net\Z}.freeze
VALID_PATH_MATCH = %r{\A/wiki(/|\Z)}.freeze
@@ -11,16 +11,10 @@ module Integrations
validates :confluence_url, presence: true, if: :activated?
validate :validate_confluence_url_is_cloud, if: :activated?
- after_commit :cache_project_has_confluence
-
def self.to_param
'confluence'
end
- def self.supported_events
- %w()
- end
-
def title
s_('ConfluenceService|Confluence Workspace')
end
@@ -80,12 +74,5 @@ module Integrations
rescue URI::InvalidURIError
false
end
-
- def cache_project_has_confluence
- return unless project && !project.destroyed?
-
- project.project_setting.save! unless project.project_setting.persisted?
- project.project_setting.update_column(:has_confluence, active?)
- end
end
end