Skip to content

Commit

Permalink
Merge pull request #54 from meet-aniket/#20jwqu1
Browse files Browse the repository at this point in the history
Improved: code to remove error while having spaces around fields on Login page (#20jwqu1).
  • Loading branch information
adityasharma7 authored Apr 6, 2022
2 parents 7c3f7dd + e9302ab commit cf511c9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions changelogs/unreleased/-20jwqu1.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: 'Improved: code to remove error while having spaces arround fields on Login page.'
ticket_id: "#20jwqu1"
merge_request: 54
author: Aniket Kumar Pandey
type: fixed
4 changes: 2 additions & 2 deletions src/views/login.vue
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,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 = ''
Expand Down

0 comments on commit cf511c9

Please sign in to comment.