module BitBucket::Validations::Presence
Public Instance Methods
_validate_presence_of(*params)
click to toggle source
Ensures that essential arguments are present before request is made
# File lib/bitbucket_rest_api/validations/presence.rb, line 9 def _validate_presence_of(*params) params.each do |param| raise ArgumentError, "parameter cannot be nil" if param.nil? end end
_validate_user_repo_params(user_name, repo_name)
click to toggle source
Check if user or repository parameters are passed
# File lib/bitbucket_rest_api/validations/presence.rb, line 18 def _validate_user_repo_params(user_name, repo_name) raise ArgumentError, "[user] parameter cannot be nil" if user_name.nil? raise ArgumentError, "[repo] parameter cannot be nil" if repo_name.nil? end