diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Matrix/Client/Requester.pm6 | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/Matrix/Client/Requester.pm6 b/lib/Matrix/Client/Requester.pm6 index 9cabf9c..ca1f0e1 100644 --- a/lib/Matrix/Client/Requester.pm6 +++ b/lib/Matrix/Client/Requester.pm6 @@ -44,13 +44,12 @@ multi method post(Str $path, Str $json, :$media = False) { my $req = HTTP::Request.new(POST => $url, Content-Type => 'application/json'); $req.add-content($json); - return self!handle-error($!ua.request($req)); } multi method post(Str $path, :$media = False, *%params) { my $json = to-json(%params); - nextwith($path, $json, :$media) + $.post($path, $json, :$media) } method post-bin(Str $path, Buf $buf, :$content-type) { |