fixed bug with empty env vars