fixed issues in dojo rules