fix device execption