fix(directory) directory attribute is ignored
fixes #18