If the user manually restarts YoNTMA from services.msc, then disconnects from AC power (without ever locking the screen), YoNTMA will hibernate the machine.
This is because when YoNTMA restarts from services.msc, it thinks it's in the never logged in state and so when the AC is disconnected, it hibernates because it thinks that no user is logged in.
Solution is likely to fine tune the "never logged in" case with a check for if the user is currently logged in.
If the user manually restarts YoNTMA from services.msc, then disconnects from AC power (without ever locking the screen), YoNTMA will hibernate the machine.
This is because when YoNTMA restarts from services.msc, it thinks it's in the never logged in state and so when the AC is disconnected, it hibernates because it thinks that no user is logged in.
Solution is likely to fine tune the "never logged in" case with a check for if the user is currently logged in.