fixed potential leakages