diff options
Diffstat (limited to 'src/ruby/lib/grpc/errors.rb')
-rw-r--r-- | src/ruby/lib/grpc/errors.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/ruby/lib/grpc/errors.rb b/src/ruby/lib/grpc/errors.rb index a1dd1e3e9d..23b2bb7e12 100644 --- a/src/ruby/lib/grpc/errors.rb +++ b/src/ruby/lib/grpc/errors.rb @@ -40,11 +40,12 @@ module GRPC # @param code [Numeric] the status code # @param details [String] the details of the exception - def initialize(code, details = 'unknown cause', **kw) + # @param metadata [Hash] the error's metadata + def initialize(code, details = 'unknown cause', metadata = {}) super("#{code}:#{details}") @code = code @details = details - @metadata = kw + @metadata = metadata end # Converts the exception to a GRPC::Status for use in the networking |