Not all the time. Previously, I used to put on the music before going to bed and when I wake up in the middle of the night, I will still meet it playing. But this day, I prefer the music to be off, not that it has any effect on me like, not allowing me to sleep properly, it just that these days I prefer to be in a meditative mood before going to sleep.
Basically, music is very soothing to the soul, and there is sensational therapeutic feelings attached to it. And so, I am not surprised why some people choose to sleep while the it is on. I know this theory might not hold much water in the hearts of many, as they would vehemently assert that it's a source of distraction to their resting period. I agree, life is always different strokes for different folks.
Finally, whichever way you choose to sleep, either the use of music or not, but the most important thing is that, you should be able to have yourself a restful night.