Yes, you're correct in thinking the O ring is a remnant of a previous time/filter type. They sometimes forget to be removed, usually by owners who haven't seen them before and only have knowledge of the later filters and just ram the new filter home. Good thing you checked, I always cast a glance down there on bikes I haven't touched before.
The only other thing to check for is the metal shim at the lid end. Ensure it's installed and undamaged, and that you use a new O ring between it and the lid. No need for a gasket, probably better off without it.
Bill.....................;-)