see this link >
https://neurosciencenews.com/euphoria-death-15656/I suspected that this may be the case a fair while ago; an excerpt:
“People often look like they are sleeping just after dying, having a neutral facial expression. But one of my relatives, who had intense pain the hours leading up to his death and lacked access to medical care, had a radiant, ecstatic expression. For decades, I have wondered whether the last minutes of life can be euphoric. Could dying perhaps trigger a flood of endorphins, in particular in the absence of painkillers?” Göran, 77, Helsingborg, Sweden.