I am trying to use an array map for checking if same username and password exist in an object array

```
database.map((obj)=>{
  if(values.name  === obj.name && values.password===obj.password){
    console.log("login success");
  } else {
    console.log("login Failed");
  }
});

```