Browse Source

Fix status creation API silently discarding invalid poll (#10171)

master
Eugen Rochko 5 years ago
committed by GitHub
parent
commit
0c43c320db
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      app/models/status.rb

+ 1
- 0
app/models/status.rb View File

@ -70,6 +70,7 @@ class Status < ApplicationRecord
validates_with StatusLengthValidator
validates_with DisallowedHashtagsValidator
validates :reblog, uniqueness: { scope: :account }, if: :reblog?
validates_associated :owned_poll
default_scope { recent }

Loading…
Cancel
Save