Question about new wake on lan integration problem

Hi, I configure the new wake on lan integration and created a switch for my lg tv. All is working great but the problem is when I turn off the tv with the remote. Obviously the switch doesn’t know it and doesn’t change to the off state and my custom button card show the tv as on. How can I solve that? Before, as I used the media player entity, there was no problem.

Thanks in advance

First why have you changed to WOL when the media player option worked?

You could just use a button helper instead of a toggle, or you could set an automation to turn off WOL after 2 minutes or so.

Because I do not know why, my lg wake on lan stopped working after the update that add the integration . I already post it about that and people told me that I have to use the new wake on lan integration