Fixed issue with circular dependencies