Pārlūkot izejas kodu

Include max image dimensions in error (#11552)

master^2
Arnout Engelen pirms 4 gadiem
committed by Eugen Rochko
vecāks
revīzija
d7bdddbeef
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. +1
    -1
      app/models/concerns/attachmentable.rb

+ 1
- 1
app/models/concerns/attachmentable.rb Parādīt failu

@@ -43,7 +43,7 @@ module Attachmentable

width, height = FastImage.size(attachment.queued_for_write[:original].path)

raise Mastodon::DimensionsValidationError, "#{width}x#{height} images are not supported" if width.present? && height.present? && (width * height >= MAX_MATRIX_LIMIT)
raise Mastodon::DimensionsValidationError, "#{width}x#{height} images are not supported, must be below #{MAX_MATRIX_LIMIT} sqpx" if width.present? && height.present? && (width * height >= MAX_MATRIX_LIMIT)
end
end



Notiek ielāde…
Atcelt
Saglabāt