-
-
Save robins35/66f6d3df822217eaffe3dcd5301a193a 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
def file_names | |
super.try(:split, ',').to_a | |
end | |
# | |
def file_names=(value) | |
joined_value = value.join(',') | |
super(joined_value) | |
end | |
def file_names<< (value) | |
if file_names.empty? | |
file_names = value | |
else | |
file_names = file_names + [value] | |
end | |
end | |
alias push << |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment