From 372f47043d3cd0b2116edb4b049d6abfb1f0105a Mon Sep 17 00:00:00 2001
From: Olav Morken <olav.morken@uninett.no>
Date: Wed, 9 Feb 2011 12:42:09 +0000
Subject: [PATCH] Error_NoState: Pass proper error code to constructor.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@2739 44740490-163a-0410-bde0-09ae8108e29a
---
 dictionaries/errors.definition.json | 6 ++++++
 lib/SimpleSAML/Error/NoState.php    | 4 +---
 2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/dictionaries/errors.definition.json b/dictionaries/errors.definition.json
index 7dd755b24..f2b9261f1 100644
--- a/dictionaries/errors.definition.json
+++ b/dictionaries/errors.definition.json
@@ -199,5 +199,11 @@
 	},
 	"descr_USERABORTED": {
 		"en": "The authentication was aborted by the user"
+	},
+	"title_NOSTATE": {
+		"en": "State information lost"
+	},
+	"descr_NOSTATE": {
+		"en": "State information lost, and no way to restart the request"
 	}
 }
diff --git a/lib/SimpleSAML/Error/NoState.php b/lib/SimpleSAML/Error/NoState.php
index b7610d476..723380726 100644
--- a/lib/SimpleSAML/Error/NoState.php
+++ b/lib/SimpleSAML/Error/NoState.php
@@ -12,11 +12,9 @@ class SimpleSAML_Error_NoState extends SimpleSAML_Error_Error {
 
 	/**
 	 * Create the error
-	 *
-	 * @param string $reason  Optional description of why the given page could not be found.
 	 */
 	public function __construct() {
-		parent::__construct('State information lost, and no way to restart the request.');
+		parent::__construct('NOSTATE');
 	}
 
 
-- 
GitLab