Skip to content

Commit

Permalink
Fixes #277
Browse files Browse the repository at this point in the history
Sequelize version was bumped along the way and now findByID is deprecated. The findByPk method works.
  • Loading branch information
dtauer authored Oct 27, 2022
1 parent e55f891 commit 44a85ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/routes/transfers.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ router.all('/perform', function(req, res) {

Promise.all(
[accountFrom, accountTo]
.map(accountId => Account.findById(accountId))
.map(accountId => Account.findByPk(accountId))
).then(([aFrom, aTo]) => {
if (!aFrom || !aTo) {
errorAndReload(req, res, 'One or more account IDs are invalid');
Expand Down

0 comments on commit 44a85ff

Please sign in to comment.