Wirekeys hangs when using JavaScript macros

Sometimes Wirekeys hangs when using JavaScript macros to process selected text. Especially this is true after the laptop is back from sleep mode. Please fix.

Version is 3.7.0, but that was true for previous versions.