Correcting regex for matching need ids

the older one was matching newlines as well.