The code I copied in is from firebug, so of course the items are closed.
And we should know that because????
if you are providing code, paste it from the source code so we get the whole picture
That way it saves wasting your time and ours pointing to problems that don't actually exist, but obviously exist in what you provide.
It's a bit like taking your cat to the vets because your dog is not well.