fix display when proxied GET yields ERROR

The error message is not displayed to the use, but this mirrors the
behavior when a regular get from a special remote fails. At least now
there is not a protocol error.
This commit is contained in:
Joey Hess 2024-07-01 11:19:02 -04:00
parent dce3848ad8
commit fa5e7463eb
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
5 changed files with 21 additions and 16 deletions

View file

@ -216,7 +216,7 @@ runNet runst conn runner f = case f of
Right () -> runner next
ReceiveMessage next ->
let protoerr = return $ Left $
ProtoFailureMessage "protocol error"
ProtoFailureMessage "protocol error 1"
gotmessage m = do
liftIO $ debugMessage conn "P2P <" m
runner (next (Just m))
@ -263,7 +263,7 @@ runNet runst conn runner f = case f of
liftIO (atomically (takeTMVar mv)) >>= \case
Left b -> runner (next b)
Right _ -> return $ Left $
ProtoFailureMessage "protocol error"
ProtoFailureMessage "protocol error 2"
CheckAuthToken _u t next -> do
let authed = connCheckAuth conn t
runner (next authed)