[Solved] Meteor.loginWithPassword error!


#1

Here is my test code:

Meteor.loginWithPassword({user: "myusername", password: "mypassword"}, (error, result) => {
                if(error){
                    console.log("Error");
                } else {
                    console.log("Done")
                }
            })

And here is the error:
Uncaught TypeError: string.charCodeAt is not a function
point to meteor://💻app/packages/sha/sha256.js
Please help!


#2

I fixed:

let user = "myusername";
let password = "mypassword";
Meteor.loginWithPassword(user, password, (error, result) => {});