Sha256: 3ce9cc301221f7d413d7111e60a307cc6ed1a76f90cbf92b5fd0d9df37bb69c5
Contents?: true
Size: 688 Bytes
Versions: 1
Compression:
Stored size: 688 Bytes
Contents
# frozen_string_literal: true module BitBucket module Validations module Presence # Ensures that essential arguments are present before request is made # def _validate_presence_of(*params) params.each do |param| raise ArgumentError, 'parameter cannot be nil' if param.nil? end end # Check if user or repository parameters are passed # 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 end # Presence end # Validations end # BitBucket
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
bitbuckets-0.2.0 | lib/bitbucket_rest_api/validations/presence.rb |