Flatpak integration in Qubes OS templates

The flatpak apps are not getting updated with the Qubes Update utility. I think the Flatpak update process gets forcefully terminated when the Qubes Update completes, which then triggers the template shutdown.

I manually executed /etc/qubes/post-install.d/05-flatpak-update.sh and it is executable. It works fine and instantly starts updating the apps. However, this is not happening when using the Qubes Update tool.

Is there a way for the script to deny the shutdown command triggered by the Qubes Update utility if an update is underway, and shut down the template only after the Flatpak updates are complete?

BTW, is there a way to confirm if the script /etc/qubes/post-install.d/05-flatpak-update.sh is actually executing with the Qubes Update utility?