nielsgl / sequelize-paper-trail

Sequelize plugin for tracking revision history of model instances.
MIT License
95 stars 69 forks source link

Allow the noPaperTrail option to be set via continuation-local-storage #101

Open jlw0 opened 4 years ago

jlw0 commented 4 years ago

User Story

As a paper trail consumer, I would like to use continuation-local-storage to set the noPaperTrail option, so that I don't need to include this option for each model/action when an endpoint is executed by a no-audit system user.

Acceptance Criteria

  1. Verify that a continuation-local-storage attribute may be set to indicate the noPaperTrail option is enabled.

  2. Verify that the sequelize-paper-trail hooks check the options for a noPaperTrail setting, and when it is not provided the noPaperTrail setting is pulled from continuation-local-storage.