[core][fr][js] merge webext2_fix: code cleaning + bug fixes + remove Array comprehensions (for compatibility)