String.removeWrap
removeWrap($prefix, $suffix) -> string
Description
Remove $prefix
and $suffix
from the beginning and end of the string, if both exist.
'(ACCEPTED)'.removeWrap('(', ')') //= 'ACCEPTED' 'ACCEPTED'.removeWrap('(', ')') //= 'ACCEPTED'