fixing bugs for monitor