removed null=true from code field