Because the share draft content controller extension is applied to the base Controller class (which doesn't have a url_segment), this can throw errors in other modules particularly when running unit tests.
We can check that it has a url_segment (happy path) to avoid this.
Because the share draft content controller extension is applied to the base Controller class (which doesn't have a url_segment), this can throw errors in other modules particularly when running unit tests.
We can check that it has a url_segment (happy path) to avoid this.
Also replace deprecated code.