Commit fff1204
committed
Prevent superadmin un-confirmation if UI bypassed
`spec/controllers/super_admin/users_controller_spec.rb`:
- Added test to prevent un-confirming of any super admin email within app
`app/controllers/super_admin/users_controller.rb`:
- Added !@user.can_super_admin? check to enable the aforementioned test to pass
- Also, updated a `patch` statement to `put`1 parent 6a69538 commit fff1204
2 files changed
Lines changed: 11 additions & 3 deletions
File tree
- app/controllers/super_admin
- spec/controllers/super_admin
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
146 | | - | |
147 | | - | |
| 146 | + | |
| 147 | + | |
148 | 148 | | |
149 | 149 | | |
150 | 150 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
44 | 52 | | |
45 | 53 | | |
0 commit comments