PGBI/cakephp3-soft-delete

Can't execute the validation of uniqueness in using this plugin .

keisukemizuno opened this issue · 1 comments

I have this validator.

    $validator
        ->requirePresence('name', 'create')
        ->add('name', 'unique', ['rule' => 'validateUnique', 'provider' => 'table', 'message' => 'must be unique !'])
        ->notEmpty('name', 'cannot be empty!');

Without using this plugin, patchEntity method returns validation errors correctly.
But using this plugin, patchEntity method returns no validation errors.

PGBI commented

If you use the soft delete plugin, the expected behavior would be to enforce uniqueness among non soft deleted records. Is it what you are observing?