Project

General

Profile

« Previous | Next » 

Revision 6768

check for non-public session in Metacat before showing the registry form
http://bugzilla.ecoinformatics.org/process_bug.cgi

View differences:

register-dataset.cgi
354 354

  
355 355
	# check if the user is logged in...
356 356
	my $session = CGI::Session->load() or die CGI::Session->errstr();
357
	
358
	# check with Metacat to see if we are actually logged in
359
	my $metacat = Metacat->new($metacatUrl);
360
	my $response = $metacat->getUserInfo();
361
	if ($response =~ "public") {
362
		$session->clear();
363
	}
364
	
357 365
	if ( $session->is_empty ) {
358 366

  
359 367
		# no session found ... redirect to login page template

Also available in: Unified diff