safety fixes