Issue #2561259 by stefan.r, lauriii, joelpittet, andypost: Cast (optgroup) array keys that may hold translated strings to string