Bug 21626: (QA follow-up) Don't crash on missing teams file
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
This commit is contained in:
parent
1edd15129c
commit
ec08e5af12
5
about.pl
5
about.pl
|
|
@ -531,7 +531,10 @@ if ( defined C4::Context->config('docdir') ) {
|
|||
}
|
||||
|
||||
## Release teams
|
||||
my $teams = LoadFile("$docdir"."/teams.yaml");
|
||||
my $teams =
|
||||
-e "$docdir" . "/teams.yaml"
|
||||
? LoadFile( "$docdir" . "/teams.yaml" )
|
||||
: {};
|
||||
my $dev_team = (sort {$b <=> $a} (keys %{$teams->{team}}))[0];
|
||||
my $short_version = substr($versions{'kohaVersion'},0,5);
|
||||
my $minor = substr($versions{'kohaVersion'},3,2);
|
||||
|
|
|
|||
|
|
@ -405,21 +405,27 @@
|
|||
</ul>
|
||||
|
||||
<h2>Koha release teams</h2>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3>Koha [% short_version | html %] release team</h3>
|
||||
[% IF development_version %]
|
||||
<p>You are running a development version of Koha</p>
|
||||
[% ELSE %]
|
||||
[% INCLUDE team t=release_team v='release' %]
|
||||
[% END %]
|
||||
</div>
|
||||
[% IF maintenance_team %]
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3>Koha [% short_version | html %] release team</h3>
|
||||
[% IF development_version %]
|
||||
<p>You are running a development version of Koha</p>
|
||||
[% ELSE %]
|
||||
[% INCLUDE team t=release_team v='release' %]
|
||||
[% END %]
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<h3>Current maintenance team</h3>
|
||||
[% INCLUDE team t=maintenance_team v=short_version %]
|
||||
<div class="col-md-6">
|
||||
<h3>Current maintenance team</h3>
|
||||
[% INCLUDE team t=maintenance_team v=short_version %]
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
[% ELSE %]
|
||||
<div class="dialog alert">
|
||||
Could not read the teams.yaml file. Please make sure <docdir> is correctly defined in koha-conf.xml.
|
||||
</div>
|
||||
[% END %]
|
||||
|
||||
<h2>Koha development team</h2>
|
||||
[% IF contributors.size %]
|
||||
|
|
|
|||
Loading…
Reference in New Issue