Skip to content

Instantly share code, notes, and snippets.

@tatey
Created August 18, 2010 11:33
Show Gist options
  • Select an option

  • Save tatey/534401 to your computer and use it in GitHub Desktop.

Select an option

Save tatey/534401 to your computer and use it in GitHub Desktop.
# Not sure if we should throw an exception or not.
def self.sequences(*sequences)
if sequences.any? && (sequences - SEQUENCES.keys).empty?
@sequences = sequences
else
raise ArgumentError, "Invalid sequence"
end
@sequences || [:in]
end
def self.sequences(*sequences)
if sequences.any?
@sequences = sequences & SEQUENCES.keys
@sequences = nil unless @sequences.any?
end
@sequences || [:in]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment