Skip to content

Commit f8c662f

Browse files
committed
Pass _csrfToken to fix 401 forbidden error
1 parent fd7e770 commit f8c662f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

resources/js/Pages/Users/Edit.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ export default {
128128
data.append('password', this.form.password || '');
129129
data.append('owner', this.form.owner ? '1' : '0');
130130
data.append('photo', this.form.photo || '');
131-
data.append('_method', 'put');
131+
data.append('_csrfToken', this.$page._csrfToken);
132132
133133
this.$inertia.post(`/users/edit/${this.user.id}`, data).then(() => {
134134
this.sending = false;

0 commit comments

Comments
 (0)