fix random code insert