artist: drop unused member_names method.
This commit is contained in:
@@ -246,12 +246,6 @@ class Artist < ApplicationRecord
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
module GroupMethods
|
|
||||||
def member_names
|
|
||||||
members.map(&:name).join(", ")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
module VersionMethods
|
module VersionMethods
|
||||||
def create_version(force=false)
|
def create_version(force=false)
|
||||||
if saved_change_to_name? || url_string_changed || saved_change_to_is_active? || saved_change_to_is_banned? || saved_change_to_other_names? || saved_change_to_group_name? || saved_change_to_notes? || force
|
if saved_change_to_name? || url_string_changed || saved_change_to_is_active? || saved_change_to_is_banned? || saved_change_to_other_names? || saved_change_to_group_name? || saved_change_to_notes? || force
|
||||||
@@ -524,7 +518,6 @@ class Artist < ApplicationRecord
|
|||||||
|
|
||||||
include UrlMethods
|
include UrlMethods
|
||||||
include NameMethods
|
include NameMethods
|
||||||
include GroupMethods
|
|
||||||
include VersionMethods
|
include VersionMethods
|
||||||
extend FactoryMethods
|
extend FactoryMethods
|
||||||
include NoteMethods
|
include NoteMethods
|
||||||
|
|||||||
@@ -408,7 +408,6 @@ class ArtistTest < ActiveSupport::TestCase
|
|||||||
cat_or_fish = FactoryBot.create(:artist, :name => "cat_or_fish")
|
cat_or_fish = FactoryBot.create(:artist, :name => "cat_or_fish")
|
||||||
yuu = FactoryBot.create(:artist, :name => "yuu", :group_name => "cat_or_fish")
|
yuu = FactoryBot.create(:artist, :name => "yuu", :group_name => "cat_or_fish")
|
||||||
|
|
||||||
assert_equal("yuu", cat_or_fish.member_names)
|
|
||||||
assert_not_nil(Artist.search(:group_name => "cat_or_fish").first)
|
assert_not_nil(Artist.search(:group_name => "cat_or_fish").first)
|
||||||
assert_not_nil(Artist.search(:any_name_matches => "cat_or_fish").first)
|
assert_not_nil(Artist.search(:any_name_matches => "cat_or_fish").first)
|
||||||
assert_not_nil(Artist.search(:any_name_matches => "/cat/").first)
|
assert_not_nil(Artist.search(:any_name_matches => "/cat/").first)
|
||||||
|
|||||||
Reference in New Issue
Block a user