{"action":"opened","issue":{"url":"https://api.github.com/repos/sonata-project/SonataBlockBundle/issues/225","labels_url":"https://api.github.com/repos/sonata-project/SonataBlockBundle/issues/225/labels{/name}","comments_url":"https://api.github.com/repos/sonata-project/SonataBlockBundle/issues/225/comments","events_url":"https://api.github.com/repos/sonata-project/SonataBlockBundle/issues/225/events","html_url":"https://github.com/sonata-project/SonataBlockBundle/issues/225","id":108750650,"number":225,"title":"Block manager injections","user":{"login":"sagikazarmark","id":1226384,"avatar_url":"https://avatars.githubusercontent.com/u/1226384?v=3","gravatar_id":"","url":"https://api.github.com/users/sagikazarmark","html_url":"https://github.com/sagikazarmark","followers_url":"https://api.github.com/users/sagikazarmark/followers","following_url":"https://api.github.com/users/sagikazarmark/following{/other_user}","gists_url":"https://api.github.com/users/sagikazarmark/gists{/gist_id}","starred_url":"https://api.github.com/users/sagikazarmark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sagikazarmark/subscriptions","organizations_url":"https://api.github.com/users/sagikazarmark/orgs","repos_url":"https://api.github.com/users/sagikazarmark/repos","events_url":"https://api.github.com/users/sagikazarmark/events{/privacy}","received_events_url":"https://api.github.com/users/sagikazarmark/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-09-28T21:29:23Z","updated_at":"2015-09-28T21:29:23Z","closed_at":null,"body":"In many cases Blocks in feature bundles accept the general manager interface to be injected. For example:\r\n\r\n``` php\r\nuse Sonata\\CoreBundle\\Model\\ManagerInterface;\r\n\r\nclass RecentPostsBlockService extends BaseBlockService\r\n{\r\n    public function __construct($name, EngineInterface $templating, ManagerInterface $manager, Pool $adminPool = null)\r\n\r\n```\r\n\r\nShouldn't these blocks accept the specific manager interface instead? In this case: `Sonata\\NewsBundle\\Model\\PostManagerInterface`?\r\n\r\nSince this interface extends the core manager interface it can simply be passed to the parent constructor.\r\n\r\nChanging these signatures is a BC break, however this is unintended behaviour IMO, so it should not be a problem."}}