BUG: Return of logpmf (Fixes #4029)

Fixes made according to #4029