diff --git a/Changelog.md b/Changelog.md index e8a2f1e7b..7027e9214 100644 --- a/Changelog.md +++ b/Changelog.md @@ -21,7 +21,7 @@ Ruby 2.0 is no longer officially supported. * Dropped db/seeds.rb [#5896](https://github.com/diaspora/diaspora/pull/5896) * Drop broken install scripts [#5907](https://github.com/diaspora/diaspora/pull/5907) * Improve invoking mobile site in the testsuite [#5915](https://github.com/diaspora/diaspora/pull/5915) -* Do not retry a couple of unrecoverable job failures [#5938](https://github.com/diaspora/diaspora/pull/5938) +* Do not retry a couple of unrecoverable job failures [#5938](https://github.com/diaspora/diaspora/pull/5938) [#5942](https://github.com/diaspora/diaspora/pull/5943) ## Bug fixes * Disable auto follow back on aspect deletion [#5846](https://github.com/diaspora/diaspora/pull/5846) diff --git a/app/workers/base.rb b/app/workers/base.rb index bb8315e50..9165da7a9 100644 --- a/app/workers/base.rb +++ b/app/workers/base.rb @@ -21,9 +21,12 @@ module Workers Rails.logger.info("error on receive: #{e.class}") rescue ActiveRecord::RecordInvalid => e Rails.logger.info("failed to save received object: #{e.record.errors.full_messages}") - raise e unless e.message.match(/already been taken/) + raise e unless %w( + "already been taken" + "is ignored by the post author" + ).any? {|reason| e.message.include? reason } rescue ActiveRecord::RecordNotUnique => e - Rails.logger.info("failed to save received object: #{e.record.errors.full_messages}") + Rails.logger.info("failed to save received object: #{e.message}") raise e unless %w( index_comments_on_guid index_likes_on_guid