First paragraph is easy, no matter whether it's one line or several. But a second paragraph with single line-breaks in it will mess you up, because "." in regexes won't match line breaks, and adding the "s" modifier on the regex to "fix" that will just break things worse.