[LON-CAPA-cvs] cvs: loncom /interface resetpw.pm
raeburn
raeburn at source.lon-capa.org
Mon Aug 21 11:25:55 EDT 2017
raeburn Mon Aug 21 15:25:55 2017 EDT
Modified files:
/loncom/interface resetpw.pm
Log:
- On a multi-domain server, the key for the current server in the hash
returned by lonnet::internet_dom_servers($udom) need not be the lonHostID.
Index: loncom/interface/resetpw.pm
diff -u loncom/interface/resetpw.pm:1.39 loncom/interface/resetpw.pm:1.40
--- loncom/interface/resetpw.pm:1.39 Sun Oct 30 01:45:31 2016
+++ loncom/interface/resetpw.pm Mon Aug 21 15:25:55 2017
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Allow access to password changing via a token sent to user's e-mail.
#
-# $Id: resetpw.pm,v 1.39 2016/10/30 01:45:31 raeburn Exp $
+# $Id: resetpw.pm,v 1.40 2017/08/21 15:25:55 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -96,9 +96,14 @@
if ($udom) {
$domdesc = &Apache::lonnet::domain($udom,'description');
if ($domdesc) {
+ $otherinst = 1;
+ my @ids=&Apache::lonnet::current_machine_ids();
my %servers = &Apache::lonnet::internet_dom_servers($udom);
- unless (exists($servers{$server})) {
- $otherinst = 1;
+ foreach my $server (keys(%servers)) {
+ if (grep(/^\Q$server\E$/, at ids)) {
+ $otherinst = 0;
+ last;
+ }
}
}
}
More information about the LON-CAPA-cvs
mailing list