Courtesy of In Shaykh's Company: a blog maintained by the students of Shaykh Muhammad Saleem Dhorat hafizahullah www.shaykh.org
Whatever is inside a persons heart will emerge at the time of death. If the love for Allāh taala is in a persons heart then at the time of death this will become apparent, and if the love of the world is in the heart then this too will show at the time of death.
Take the example of a parrot; you can teach it to say the word Allāh and it may say Allāh all day long. However, when a cat pounces at it, only then will the reality emerge, i.e. it will resort to its natural voice and squawk in alarm. It will not say Allāh, as it was merely on its tongue, not in its heart.
Similarly, someone who outwardly shows religiosity will not be able to depart with Imān, whilst the one whose heart is illuminated with the love of Allāh taala will leave happily with the kalimah on his tongue.
Therefore, we must strive to illuminate our heart with the love of Allāh taala so that we depart from this world towards Jannah wholeheartedly with this love and remembrance.