def post_template_populate(self):
        current_post = getattr(self.request, get_setting('CURRENT_POST_IDENTIFIER'), None)
        if current_post and self.request.user.has_perm('djangocms_blog.change_post'):  # pragma: no cover  # NOQA
            # removing page meta menu, if present, to avoid confusion
            try:   # pragma: no cover
                import djangocms_page_meta  # NOQA
                menu = self.request.toolbar.get_or_create_menu('page')
                pagemeta = menu.get_or_create_menu('pagemeta', 'meta')
                menu.remove_item(pagemeta)
            except __HOLE__:
                pass
            # removing page tags menu, if present, to avoid confusion
            try:   # pragma: no cover
                import djangocms_page_tags  # NOQA
                menu = self.request.toolbar.get_or_create_menu('page')
                pagetags = menu.get_or_create_menu('pagetags', 'tags')
                menu.remove_item(pagetags)
            except ImportError:
                pass
            self.add_publish_button()
dataset/ETHPy150Open nephila/djangocms-blog/djangocms_blog/cms_toolbar.py/BlogToolbar.post_template_populate