mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-10-19 20:16:04 +08:00
fix: result screen showing pb mismatch when bailing out of long tests
This commit is contained in:
parent
e21a205c0a
commit
23948f0d9f
1 changed files with 8 additions and 1 deletions
|
@ -482,8 +482,9 @@ async function resultCanGetPb(): Promise<CanGetPbObject> {
|
|||
const funboxesOk =
|
||||
result.funbox === "none" || funboxes.length === 0 || allFunboxesCanGetPb;
|
||||
const notUsingStopOnLetter = Config.stopOnError !== "letter";
|
||||
const notBailedOut = !result.bailedOut;
|
||||
|
||||
if (funboxesOk && notUsingStopOnLetter) {
|
||||
if (funboxesOk && notUsingStopOnLetter && notBailedOut) {
|
||||
return {
|
||||
value: true,
|
||||
};
|
||||
|
@ -500,6 +501,12 @@ async function resultCanGetPb(): Promise<CanGetPbObject> {
|
|||
reason: "stop on letter",
|
||||
};
|
||||
}
|
||||
if (!notBailedOut) {
|
||||
return {
|
||||
value: false,
|
||||
reason: "bailed out",
|
||||
};
|
||||
}
|
||||
return {
|
||||
value: false,
|
||||
reason: "unknown",
|
||||
|
|
Loading…
Add table
Reference in a new issue