({ username, email, password })
| 156 | } |
| 157 | |
| 158 | static async createSuperUser({ username, email, password }) { |
| 159 | try { |
| 160 | const response = await request( |
| 161 | `${host}/api/accounts/initialize-superuser/`, |
| 162 | { |
| 163 | auth: false, |
| 164 | method: 'POST', |
| 165 | body: { |
| 166 | username, |
| 167 | password, |
| 168 | email, |
| 169 | }, |
| 170 | } |
| 171 | ); |
| 172 | |
| 173 | return response; |
| 174 | } catch (e) { |
| 175 | errorNotification('Failed to create superuser', e); |
| 176 | } |
| 177 | } |
| 178 | |
| 179 | static async login(username, password) { |
| 180 | try { |
no test coverage detected