Skip to content

Commit

Permalink
This line should never have been removed
Browse files Browse the repository at this point in the history
Whoops? This removed the wrong if statement.

https://github.com/alanmcgovern/monotorrent/pull/604/files
  • Loading branch information
alanmcgovern committed Feb 2, 2023
1 parent 096f1bd commit 3159b44
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -786,6 +786,9 @@ public async Task StopAsync (TimeSpan timeout)
{
await ClientEngine.MainLoop;

if (Mode is StoppingMode)
throw new TorrentException ("The manager cannot be stopped while it is already in the Stopping state.");

if (State == TorrentState.Error) {
Error = null;
Mode = new StoppedMode ();
Expand Down

0 comments on commit 3159b44

Please sign in to comment.