style(rubocop): Lint/DuplicateMethods

This commit is contained in:
Adam Cooke
2024-02-12 09:55:18 +00:00
parent a1dc0f77ac
commit bab6346239
2 changed files with 4 additions and 0 deletions
+2
View File
@@ -31,6 +31,7 @@ class IncomingMessagePrototype
end
end
# rubocop:disable Lint/DuplicateMethods
def attachments
(@attachments || []).map do |attachment|
{
@@ -40,6 +41,7 @@ class IncomingMessagePrototype
}
end
end
# rubocop:enable Lint/DuplicateMethods
def create_messages
if valid?
+2
View File
@@ -93,6 +93,7 @@ class OutgoingMessagePrototype
@errors || {}
end
# rubocop:disable Lint/DuplicateMethods
def attachments
(@attachments || []).map do |attachment|
{
@@ -102,6 +103,7 @@ class OutgoingMessagePrototype
}
end
end
# rubocop:enable Lint/DuplicateMethods
def validate
@errors = []