cleaning code, monir fixes