My suggestion is not to exit in zypper ref, but rather raise the error and proceed with refreshing repos for remaining services. User will realize that there is some old broken service, while seeing this error on each refresh. Exit masks the issue a bit in my opinion.