DNS setting stays on WiFi after disconnect Mac Client

I have a issue where my DNS server that I set on the VPN server will stick as the DNS server on my Mac clients after they have been disconnected from the VPN causing issues.

The problem occurs when the end user do not disconnect from the VPN server properly in the client and instead just closes the laptop and goes on with their day.

While I understand that this is not the correct way to disconnect from the VPN server, it will be the way end users do it most of the time no matter what you tell them.

What is the reason behind this issue, and is it something I can do on the server-side to mitigate the issue?

After the issue occurs run the commands below to get the DNS state.

sudo scutil --dns
sudo scutil
> open
> show State:/Network/Global/DNS
> show State:/Network/Pritunl/DNS
> show State:/Network/Pritunl/Restore
> quit