Tweaks to caselog titles.

[#54124735]
Return empty array when querying DB for nonexistent user

(copy 72670b9c6313d10 into non-3.2 version)