Question: I am new to Sails and facing a small issue with models.  

I have defined a user model as follows: 

```
module.exports = {  
  attributes: {
   firstName: {
     type: 'string'
   },
   lastName: {
      type: 'string'
   },
   email: {
     type: 'email',
     required: true
   },

   password: {
     type: 'String'
   },
   passwordSalt: {
     type: 'String'
   },
   projects:{
     collection: 'ProjectMember',
     via: 'userId'
   }
 }
};  

```

I have one more model called Plan which has user as its foreign key: 

```
module.exports = {
   planId: { type: 'string'},
   userId: { model: 'User'}
};  

```

Now Plan stores all user data. Is there any way I can restrict Plan model to hold only some of User details like firstName, lastName, email and projectMembers instead of storing other personal info. like password, passwordSalt, etc? 

Thanks In Advance

Answer: 
Overriding `Equals` in this situation seems a little overkill here, why not just do

```
currentPerson.Vessels.Any(x => x.ID == currentVessel.ID)

```
change 

```
if (currentPerson.Vessels.Contains(currentVessel))
{
    return true;
}
else
    return false;

```

to

```
return currentPerson.Vessels.Any(x => x.ID == currentVessel.ID)

```