From 5c8cc67d62aef96d0d7fa0900b92b936df25ca83 Mon Sep 17 00:00:00 2001
From: Mads Freek Petersen <freek@wayf.dk>
Date: Fri, 22 Oct 2010 13:19:19 +0000
Subject: [PATCH] Fixed error if proxyValidate was used.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@2591 44740490-163a-0410-bde0-09ae8108e29a
---
 modules/casserver/www/serviceValidate.php | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/casserver/www/serviceValidate.php b/modules/casserver/www/serviceValidate.php
index 86ca87f2b..5de8a45b6 100644
--- a/modules/casserver/www/serviceValidate.php
+++ b/modules/casserver/www/serviceValidate.php
@@ -66,7 +66,7 @@ try {
 
 function returnResponse($value, $function, $usrname = '', $attributes = array(), $xtraxml = "") {
 	if ($value === 'YES') {	
-		if ($function == 'serviceValidate') {
+		if ($function != 'validate') {
 			$attributesxml = "";
 			foreach ($attributes as $attributename => $attributelist) {
 				$attr = htmlspecialchars($attributename);
@@ -86,7 +86,7 @@ function returnResponse($value, $function, $usrname = '', $attributes = array(),
 			echo 'yes' . "\n" . $usrname;
 		}
 	} else {
-		if ($function == 'serviceValidate') {
+		if ($function != 'validate') {
 			echo '<cas:serviceResponse xmlns:cas="http://www.yale.edu/tp/cas">
 <cas:authenticationFailure code="">
 </cas:authenticationFailure>
-- 
GitLab