1
0
mirror of https://github.com/danog/MadelineProto.git synced 2024-11-30 06:39:01 +01:00

One more cancellation

This commit is contained in:
Daniil Gentili 2024-06-26 18:28:15 +02:00
parent 658d7adb86
commit 579e280239
3 changed files with 4 additions and 4 deletions

2
docs

@ -1 +1 @@
Subproject commit 0385b677fe87246a0ae35b362929b96dd3ffcccd
Subproject commit 2da03b4f6e1d3136996f066c536df72eda2e293c

View File

@ -617,9 +617,9 @@ abstract class InternalDoc
*
* @param string $url URL
*/
final public function fileGetContents(string $url): string
final public function fileGetContents(string $url, ?\Amp\Cancellation $cancellation = null): string
{
return $this->wrapper->getAPI()->fileGetContents($url);
return $this->wrapper->getAPI()->fileGetContents($url, $cancellation ?? $this->wrapper->getRpcDropCancellation());
}
/**
* Asynchronously lock a file

View File

@ -310,7 +310,7 @@ final class VoIPController
return $this;
} catch (CallAlreadyDeclinedError) {
$this->log(Lang::$current_lang['call_already_declined']);
$this->discard(DiscardReason::HANGUP, cancellation: $cancellation);
$this->discard(DiscardReason::HANGUP);
return $this;
}
$this->call['b'] = $b;