objection-remove-sensitive-fields

1.0.1 • Public • Published

Remove sensitive data from model during JSON output in objection

Usage

const { Model, mixin } = require('objection')

const RemoveSensitiveFields = require('objection-remove-sensitive-fields')

class User extends mixin(Model, [RemoveSensitiveFields]) {
  static sensitiveFields = ['salt','password']
}

What I don't know yet.

Side-Effects as I have just started in objection

Package Sidebar

Install

npm i objection-remove-sensitive-fields

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

2.69 kB

Total Files

4

Last publish

Collaborators

  • varunbatrait