Use callMethod() because call() is reserved

This commit is contained in:
Arsen Musayelyan 2022-06-02 18:54:00 -07:00
parent 1e8e304f01
commit 368c7333c5
1 changed files with 3 additions and 3 deletions

View File

@ -67,10 +67,10 @@ class LRPCClient
@callMap.delete(val.ID) unless fns.isChannel
end
end
# call calls a method on the server with the given
# argument and returns a promise.
def call(rcvr, method, arg)
def callMethod(rcvr, method, arg)
return Promise.new do |resolve, reject|
# Get random UUID (this only works with TLS)
id = crypto.randomUUID()
@ -119,7 +119,7 @@ class LRPCChannel
# done cancels the context corresponding to the channel
# on the server side and closes the channel.
def done()
@client.call("lrpc", "ChannelDone", @id)
@client.callMethod("lrpc", "ChannelDone", @id)
self.close()
@client._callMap.delete(@id)
end