-
-
Save mipearson/1cb87f7eadbae14a829c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Admin::VideosHelper | |
def any_are_blank? r, check | |
(check.find { |j| r.send(j).blank? }) != nil | |
end | |
def any_not_exist? r, check | |
(check.find { |j| !r.send(j).exists? }) != nil | |
end | |
end | |
# r.en_title.blank? || r.ar_title.blank? || r.fr_title.blank? || !r.cover_en.exists? || !r.cover_ar.exists? || !r.cover_fr.exists? || !r.insert_en.exists? || !r.insert_ar.exists? || !r.insert_fr.exists? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment