I have seen the following sentence in a published book:
Sentence A
There were a toothbrush, a piece of floss, and a tube of toothpaste.
It sounds wrong to my ear. I would write
Sentence B
There was a toothbrush, a piece of floss, and a tube of toothpaste.
This is because I believe the verb should agree with the nearest noun, i.e., "a toothbrush".
Is the original sentence correct, or are both versions correct? Many thanks