Added conditionals on head
Modified head