use a fix suggested by @Lexicality