Add getenv() and attempt to fixes softdeletingtrait.

Signed-off-by: crynobone <crynobone@gmail.com>