Updated code release function