Fix isLastTrack test and add isLastTrack function to Album model