XDG_SESSION_TYPE on VNC server

Hi everyone.

I reported this vnc error on :
https://ubuntu-mate.community/t/vnc-display-issue-with-the-plank/23490
Unfortunately nobody was interested in that topic :joy: . But as least I found a temporary solution myself.

When a user log in locally to the desktop GUI:

$echo XDG_SESSION_TYPE
x11

When the same user login to tiger vnc server remotely:

$echo XDG_SESSION_TYPE
unspecified

Plank won't work on the vnc user due to this error. I don't think this is a vnc issue, I googled online that this should be pam_systemd issue. I couldn't find any solution though. I really wish XDG_SESSION_TYPE can be modified on vnc server side. Hopefully someone could solve this issue in the next Ubuntu version. Cheers.