]> Lady’s Gitweb - Gitweb/commit
gitweb: Refactor checking if part of project info need filling
authorJakub Narebski <redacted>
Thu, 23 Feb 2012 15:54:46 +0000 (16:54 +0100)
committerLady <redacted>
Mon, 6 Apr 2026 04:51:32 +0000 (00:51 -0400)
commit09638a04507d573146dd8bcae1a347b69def5381b292c12042c7ffe09570a5fb
treee916cfae529ab57c41774f75e9d252e2bcf8d659598afb9a984f55efaf2f42c8
parent522dd2e5ade08a3349a0fe5fb0df8b72f391fd93208825b19cc151d3e6227a5f
gitweb: Refactor checking if part of project info need filling

Extract the check if given keys (given parts) of project info needs to
be filled into project_info_needs_filling() subroutine.  It is for now
a thin wrapper around "!exists $project_info->{$key}".

Note that !defined was replaced by more correct !exists.

While at it uniquify treating of all project info, adding checks for
'age' field before running git_get_last_activity(), and also checking
for all keys filled in code protected by conditional, and not only
one.

The code now looks like this

  foreach my $project (@$project_list) {
   if (given keys need to be filled) {
   fill given keys
   }
   ...
  }

Signed-off-by: Jakub Narebski <redacted>
Signed-off-by: Junio C Hamano <redacted>
gitweb.perl
This page took 0.025053 seconds and 4 git commands to generate.