nl_tokens: Adds required () validation constraints to all the bookshelfModel s foreign keys as defined in baseQuery .
pl_tokens: function addConstraintsForForeignKeys ( bookshelfModel , baseQuery ) { if ( typeof baseQuery === 'undefined' ) { return } _ . forEach ( baseQuery ( { params : { } , payload : { } } ) , function ( v , k ) { const value = bookshelfModel . prototype . schema [ k ] if ( typeof value === 'undefined' ) { bookshelfModel . prototype . schema [ k ] = Joi . any ( ) . required ( ) } else if ( <mask> . isJoi ) { bookshelfModel . prototype . schema [ k ] = bookshelfModel . prototype . schema [ k ] . required ( ) } } ) }