Skip to content

Commit

Permalink
Merge branch 'master' of github.com:getcanoe/canoe
Browse files Browse the repository at this point in the history
  • Loading branch information
gokr committed Apr 19, 2018
2 parents 411afb8 + a81e242 commit 496b84b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/js/controllers/tab-receive.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ angular.module('canoeApp.controllers').controller('tabReceiveController', functi

var checkSelectedAccount = function (account, accounts) {
if (!account) return accounts[0]
var w = lodash.find(accounts, function (w) {
var w = lodash.findIndex(accounts, function (w) {
return w.id === account.id
})
if (!w) return accounts[0]
return account
return accounts[w]
}

$scope.onAccountSelect = function (acc) {
Expand Down
4 changes: 2 additions & 2 deletions src/js/controllers/tab-send.js
Original file line number Diff line number Diff line change
Expand Up @@ -192,11 +192,11 @@ angular.module('canoeApp.controllers').controller('tabSendController', function

var checkSelectedAccount = function (account, accounts) {
if (!account) return accounts[0]
var w = lodash.find(accounts, function (w) {
var w = lodash.findIndex(accounts, function (w) {
return w.id === account.id
})
if (!w) return accounts[0]
return account
return accounts[w]
}

$scope.$on('$ionicView.beforeEnter', function (event, data) {
Expand Down

0 comments on commit 496b84b

Please sign in to comment.