Commit a9873a47 authored by Taylor Otwell's avatar Taylor Otwell

added lang::has method.

parent 0c69b2c0
......@@ -73,6 +73,18 @@ class Lang {
return new static($key, $replacements, $language);
}
/**
* Determine if a language line exists.
*
* @param string $key
* @param string $language
* @return bool
*/
public static function has($key, $language = null)
{
return ! is_null(static::line($key, array(), $language)->get());
}
/**
* Get the language line as a string.
*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment