This repository was archived by the owner on Feb 23, 2024. It is now read-only.
Commit 3cee644
Check that the callback for filtering payment methods is available and is a function before trying to run it (#7377)
* Check callback for payment method is available before trying to run it
* Check if callback is a function before trying to run it
* Update tests to ensure callbacks only run if they are registered1 parent d246ff3 commit 3cee644
File tree
2 files changed
+18
-0
lines changed- assets/js/blocks-registry/payment-methods
- test
2 files changed
+18
-0
lines changedLines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
53 | 59 | | |
54 | 60 | | |
55 | 61 | | |
| |||
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
91 | 94 | | |
92 | 95 | | |
93 | 96 | | |
| |||
202 | 205 | | |
203 | 206 | | |
204 | 207 | | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
205 | 217 | | |
206 | 218 | | |
0 commit comments