diff --git a/changelogs/unreleased/-20jwqu1.yml b/changelogs/unreleased/-20jwqu1.yml new file mode 100644 index 00000000..86cc3af0 --- /dev/null +++ b/changelogs/unreleased/-20jwqu1.yml @@ -0,0 +1,6 @@ +--- +title: 'Improved: code to remove login error when having spaces in the fields.' +ticket_id: "#20jwqu1" +merge_request: 32 +author: Aniket Kumar Pandey +type: fixed diff --git a/src/views/Login.vue b/src/views/Login.vue index a84a05fd..4223520d 100644 --- a/src/views/Login.vue +++ b/src/views/Login.vue @@ -69,9 +69,9 @@ export default defineComponent({ }, methods: { login: function () { - this.store.dispatch("user/setUserInstanceUrl", this.instanceUrl) + this.store.dispatch("user/setUserInstanceUrl", this.instanceUrl.trim()) const { username, password } = this; - this.store.dispatch("user/login", { username, password }).then((data: any) => { + this.store.dispatch("user/login", { username: username.trim(), password }).then((data: any) => { if (data.token) { this.username = '' this.password = ''