fix HubError type check

This commit is contained in:
David Lechner
2021-01-22 15:58:10 -06:00
parent c1c08e5ced
commit b58ec9a754
+1 -4
View File
@@ -35,10 +35,7 @@ export enum HubError {
}
function isHubError(arg: unknown): arg is HubError {
if (typeof arg !== 'string') {
return false;
}
return Object.keys(HubError).includes(arg);
return Object.values(HubError).includes(arg as HubError);
}
export enum FailToFinishReasonType {