mirror of
https://git.kescher.at/CatCatNya/catstodon.git
synced 2024-11-22 17:38:07 +01:00
Fix Lint/SymbolConversion
cop (#28175)
This commit is contained in:
parent
aa8563d43d
commit
5631f139c1
4 changed files with 4 additions and 4 deletions
|
@ -5,7 +5,7 @@ module Remotable
|
||||||
|
|
||||||
class_methods do
|
class_methods do
|
||||||
def remotable_attachment(attachment_name, limit, suppress_errors: true, download_on_assign: true, attribute_name: nil)
|
def remotable_attachment(attachment_name, limit, suppress_errors: true, download_on_assign: true, attribute_name: nil)
|
||||||
attribute_name ||= "#{attachment_name}_remote_url".to_sym
|
attribute_name ||= :"#{attachment_name}_remote_url"
|
||||||
|
|
||||||
define_method("download_#{attachment_name}!") do |url = nil|
|
define_method("download_#{attachment_name}!") do |url = nil|
|
||||||
url ||= self[attribute_name]
|
url ||= self[attribute_name]
|
||||||
|
|
|
@ -62,7 +62,7 @@ class UserSettings::Setting
|
||||||
|
|
||||||
def key
|
def key
|
||||||
if namespace
|
if namespace
|
||||||
"#{namespace}.#{name}".to_sym
|
:"#{namespace}.#{name}"
|
||||||
else
|
else
|
||||||
name
|
name
|
||||||
end
|
end
|
||||||
|
|
|
@ -20,7 +20,7 @@ namespace :systemd do
|
||||||
SYSTEMD_SERVICES.each do |service|
|
SYSTEMD_SERVICES.each do |service|
|
||||||
SERVICE_ACTIONS.each do |action|
|
SERVICE_ACTIONS.each do |action|
|
||||||
desc "Perform a #{action} on #{service} service"
|
desc "Perform a #{action} on #{service} service"
|
||||||
task "#{service}:#{action}".to_sym do
|
task :"#{service}:#{action}" do
|
||||||
on roles(:app) do
|
on roles(:app) do
|
||||||
# runs e.g. "sudo restart mastodon-sidekiq.service"
|
# runs e.g. "sudo restart mastodon-sidekiq.service"
|
||||||
sudo :systemctl, action, "#{fetch(:application)}-#{service}.service"
|
sudo :systemctl, action, "#{fetch(:application)}-#{service}.service"
|
||||||
|
|
|
@ -31,7 +31,7 @@ RSpec.describe Remotable do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
let(:attribute_name) { "#{hoge}_remote_url".to_sym }
|
let(:attribute_name) { :"#{hoge}_remote_url" }
|
||||||
let(:code) { 200 }
|
let(:code) { 200 }
|
||||||
let(:file) { 'filename="foo.txt"' }
|
let(:file) { 'filename="foo.txt"' }
|
||||||
let(:foo) { foo_class.new }
|
let(:foo) { foo_class.new }
|
||||||
|
|
Loading…
Reference in a new issue