Regex Exec zawodzi dwa razy

reg.lastIndex = 0;
florinrelea