It's true that God looks mainly at the heart. Since we are human, often external distractions, our own emotions, feelings, and physical discomfort, etc. go against the heart's inclination. As Jesus said, "The spirit is willing, but the flesh is weak." This is where the mind should step in. Even if one is going through dark nights losing all feelings of God's presence, the mind can still take charge and help him carry on the task of loving God.