Fix computing cards (#8894)

Co-authored-by: Bram Kragten <mail@bramkragten.nl>
This commit is contained in:
Jakub Dąbrowski
2021-04-13 16:25:48 +02:00
committed by GitHub
co-authored by Bram Kragten
parent 96bc3ef99a
commit 62a0cfb0f6
@@ -181,7 +181,7 @@ export const computeCards = (
titlePrefix &&
stateObj &&
// eslint-disable-next-line no-cond-assign
(name = computeStateName(stateObj)).startsWith(titlePrefix)
(name = computeStateName(stateObj)) !== titlePrefix && name.startsWith(titlePrefix)
? {
entity: entityId,
name: adjustName(name.substr(titlePrefix.length)),