mirror of
https://github.com/getgrav/grav.git
synced 2026-08-31 04:35:54 +02:00
Fix for untranslated validation messages #246
This commit is contained in:
@@ -76,7 +76,8 @@ class Blueprint
|
||||
try {
|
||||
$this->validateArray($data, $this->nested);
|
||||
} catch (\RuntimeException $e) {
|
||||
throw new \RuntimeException(sprintf('<b>Validation failed:</b> %s', $e->getMessage()));
|
||||
$language = self::getGrav()['language'];
|
||||
throw new \RuntimeException(sprintf('<b>Validation failed:</b> %s', $language->translate($e->getMessage())));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user