-
-
Save dgmcguire/5df7e3dd1d9fb1b65b083930c3e0bd83 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
private def valid_tx_type?(tx_type) | |
allowed_types = %w(query commit) | |
if allowed_types.map(&:to_sym).include?(tx_type) | |
return true | |
else | |
raise ArgumentError, "tx_type must be one of the following: :#{allowed_types.join(' :')}" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment