Because it's in my common module, I want to keep the possibility open that I might add in more statuses. Hence the failure check would have to be any negative number, not specific ones. This is why I went with regex. Ofc I note that my regex matches any number in the example, but in my real code, I address that.
And yes, the success string will never be just a number. At the very least even if "" is passed as the folder and -1 is passed as the number and it passes all checks, the sub would return "/-1"