added some safty