fix: Adiciona o módulo Captain::Assistant para resolver NameError, inclui a execução de migrações no workflow de CI e trata a ausência da variável GIT_HASH.
This commit is contained in:
parent
803a85d88a
commit
88730d68bc
3
.github/workflows/run_foss_spec.yml
vendored
3
.github/workflows/run_foss_spec.yml
vendored
@ -118,6 +118,9 @@ jobs:
|
||||
- name: Seed database
|
||||
run: bundle exec rake db:schema:load
|
||||
|
||||
- name: Run migrations
|
||||
run: bundle exec rake db:migrate
|
||||
|
||||
- name: Run backend tests (parallelized)
|
||||
run: |
|
||||
# Get all spec files and split them using round-robin distribution
|
||||
|
||||
@ -28,7 +28,7 @@ class SuperAdmin::InstanceStatusesController < SuperAdmin::ApplicationController
|
||||
end
|
||||
|
||||
def sha
|
||||
@metrics['Git SHA'] = GIT_HASH
|
||||
@metrics['Git SHA'] = defined?(GIT_HASH) ? GIT_HASH : 'n/a'
|
||||
end
|
||||
|
||||
def postgres_status
|
||||
|
||||
@ -147,8 +147,10 @@ class Notification < ApplicationRecord
|
||||
|
||||
if content.present?
|
||||
transform_user_mention_content(content.truncate_words(10))
|
||||
elsif attachments.present?
|
||||
'Attachment'
|
||||
else
|
||||
attachments.present? ? I18n.t('notifications.attachment') : I18n.t('notifications.no_content')
|
||||
I18n.t('notifications.no_content')
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
5
app/services/captain/assistant.rb
Normal file
5
app/services/captain/assistant.rb
Normal file
@ -0,0 +1,5 @@
|
||||
module Captain
|
||||
module Assistant
|
||||
# Base module to fix NameError
|
||||
end
|
||||
end
|
||||
Loading…
Reference in New Issue
Block a user