Minimum match to the first slash or end