Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added missing file

  • Loading branch information...
commit cb2c97eb3f5d2be7b7ea49c3b7e2baa37cc40bf0 1 parent 1712f10
@lunetics authored
Showing with 34 additions and 0 deletions.
  1. +34 −0 Validator/LocaleAllowed.php
View
34 Validator/LocaleAllowed.php
@@ -0,0 +1,34 @@
+<?php
+/**
+ * This file is part of the LuneticsLocaleBundle package.
+ *
+ * <https://github.com/lunetics/LocaleBundle/>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that is distributed with this source code.
+ */
+
+namespace Lunetics\LocaleBundle\Validator;
+
+use Symfony\Component\Validator\Constraint;
+
+/**
+ * LocaleAllowed Constraint
+ *
+ * @Annotation
+ */
+class LocaleAllowed extends Constraint
+{
+ /**
+ * @var string
+ */
+ public $message = 'The locale "%string%" is not allowed by application configuration.';
+
+ /**
+ * {@inheritDoc}
+ */
+ public function validatedBy()
+ {
+ return 'lunetics_locale.validator.locale_allowed';
+ }
+}
Please sign in to comment.
Something went wrong with that request. Please try again.