public function substringBeforeFirst($s, $separator)
	{
		$s = SubStringy::create($s)->substringBeforeFirst($separator);
		return ($s === false ? null : $s);
	}
public function substringBeforeFirst($s, $separator)
	{
		$s = SubStringy::create($s)->substringBeforeFirst($separator);
		return ($s === false ? null : $s);
	}
public function substringBeforeFirst ( $ s , $ separator ) { $ s = SubStringy :: create ( $ s ) -> substringBeforeFirst ( $ separator ) ; return ( $ s === false ? null : $ s ) ; }
Gets the substring before the first occurrence of a separator.
If no match is found returns an empty string.

(We're hijacking the return from SubStringy to return a `null` instead of boolean `false` if the substring isn't matched.)

c.f. SubStringy::substringBeforeFirst()

@param string $s
@param string $separator

@return Word
Gets the substring before the first occurrence of a separator . If no match is found returns an empty string .