[FIX] api: clear environments on module installation