Apologies - just noticed the "if os.path.dirname(x['fileName']) == self.path]" part.. It's getting late.
Apologies - just noticed the "if os.path. dirname( x['fileName' ]) == self.path]" part.. It's getting late.