Fix first line function