def _delete(self, opts):
    if ((opts.dataverse is None) and (opts.scope is None)):
        _exit_if_errors(['--dataverse or --scope is required to delete a link'])
    if (opts.name is None):
        _exit_if_errors(['--name is required to delete a link'])
    if opts.dataverse:
        opts.scope = opts.dataverse
    (_, errors) = self.rest.delete_analytics_link(opts.scope, opts.name)
    _exit_if_errors(errors)
    _success('Link deleted')
def _delete(self, opts):
    if ((opts.dataverse is None) and (opts.scope is None)):
        _exit_if_errors(['--dataverse or --scope is required to delete a link'])
    if (opts.name is None):
        _exit_if_errors(['--name is required to delete a link'])
    if opts.dataverse:
        opts.scope = opts.dataverse
    (_, errors) = self.rest.delete_analytics_link(opts.scope, opts.name)
    _exit_if_errors(errors)
    _success('Link deleted')