logic Fix