mirror of
https://github.com/henrywhitaker3/Speedtest-Tracker.git
synced 2025-12-21 13:23:04 +01:00
Fixed some bugs
- Didn't add token to URL for settings - Auth collapse wouldn't hide
This commit is contained in:
@@ -15,7 +15,7 @@ export default class Authentication extends Component {
|
||||
}
|
||||
|
||||
toggleCollapse = () => {
|
||||
if(this.state.show) {
|
||||
if(this.state.showCollapse) {
|
||||
this.setState({
|
||||
showCollapse: false
|
||||
});
|
||||
@@ -27,7 +27,7 @@ export default class Authentication extends Component {
|
||||
}
|
||||
|
||||
toggleModal = () => {
|
||||
if(this.state.show) {
|
||||
if(this.state.showModal) {
|
||||
this.setState({
|
||||
showModal: false
|
||||
});
|
||||
|
||||
@@ -57,6 +57,9 @@ export default class ResetPassword extends Component {
|
||||
.then((resp) => {
|
||||
toast.success('Password updated');
|
||||
this.toggleModal();
|
||||
if(this.state.logoutDevices == true) {
|
||||
location.reload(true);
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
if(err.response) {
|
||||
|
||||
2
resources/js/components/Settings/Setting.js
vendored
2
resources/js/components/Settings/Setting.js
vendored
@@ -20,7 +20,7 @@ export default class Setting extends Component {
|
||||
}
|
||||
|
||||
update = () => {
|
||||
var url = 'api/settings';
|
||||
var url = 'api/settings?token=' + window.token;
|
||||
var data = {
|
||||
name: this.state.name,
|
||||
value: this.state.value
|
||||
|
||||
@@ -23,7 +23,7 @@ export default class SettingWithModal extends Component {
|
||||
}
|
||||
|
||||
update = () => {
|
||||
var url = 'api/settings/bulk';
|
||||
var url = 'api/settings/bulk?token=' + window.token;
|
||||
var data = [];
|
||||
var settings = this.state.settings;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user