fix/focus-timer-view (#26)
* Auto focus button in timer view * Revert find projects by identifier without alphanumerical characters * Update changelog
This commit is contained in:
committed by
Tobias Miesel
parent
76d57729f4
commit
12c8b8e3eb
@@ -25,7 +25,6 @@ export const ERROR_UNKNOWN = "unknown"
|
||||
|
||||
export const noop = () => null
|
||||
export const asArray = input => (Array.isArray(input) ? input : [input])
|
||||
export const removeNonAlphanumChars = input => String(input ?? "").replace(/[\W_]/g, "")
|
||||
|
||||
export const findProjectBy = prop => val => projects => {
|
||||
if (!val) {
|
||||
@@ -33,11 +32,7 @@ export const findProjectBy = prop => val => projects => {
|
||||
}
|
||||
|
||||
return compose(
|
||||
find(
|
||||
project =>
|
||||
project[prop] === val ||
|
||||
removeNonAlphanumChars(project[prop]) === removeNonAlphanumChars(val),
|
||||
),
|
||||
find(pathEq(prop, val)),
|
||||
flatMap(get("options")),
|
||||
)(projects)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user