(
filters: MutationFilters,
)
| 202 | } |
| 203 | |
| 204 | find< |
| 205 | TData = unknown, |
| 206 | TError = DefaultError, |
| 207 | TVariables = any, |
| 208 | TOnMutateResult = unknown, |
| 209 | >( |
| 210 | filters: MutationFilters, |
| 211 | ): Mutation<TData, TError, TVariables, TOnMutateResult> | undefined { |
| 212 | const defaultedFilters = { exact: true, ...filters } |
| 213 | |
| 214 | return this.getAll().find((mutation) => |
| 215 | matchMutation(defaultedFilters, mutation), |
| 216 | ) as Mutation<TData, TError, TVariables, TOnMutateResult> | undefined |
| 217 | } |
| 218 | |
| 219 | findAll(filters: MutationFilters = {}): Array<Mutation> { |
| 220 | return this.getAll().filter((mutation) => matchMutation(filters, mutation)) |
no test coverage detected