cleanenv icon indicating copy to clipboard operation
cleanenv copied to clipboard

Env-required with empty variable

Open evgeek opened this issue 1 year ago • 1 comments

Hi! I have a question about the env-required validation rule.

It works fine when the variable is not present in the .env file. But if it is present and empty - the validation error is not triggered. Is this the expected behavior? In my opinion, a required variable cannot be empty.

Or maybe this is another way to ensure such a check?

evgeek avatar Aug 29 '24 09:08 evgeek

I have ran into this issue too. IMO if a variable is empty it should fail when env-required:"true"

AlecSmith96 avatar Sep 22 '25 10:09 AlecSmith96