OS X 10.13.6, AFPUB 1.7.3.
I noted that the word "Rec" as in "rec room" was learned and no longer has a red line underneath.
However, in a different part of the document "rec" is spelled with a lower-case "r" - this has a red "spelling error" line under it. And, when I try to "learn spelling" that option is not available. Instead, the option to "unlearn spelling" is presented.
So AFPUB thinks that word has been "learned" but still underlines in red the lower-case version. Catch-22.