some bug tweaks