solving some bug