]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Render.pm
typos
[git.ikiwiki.info.git] / IkiWiki / Render.pm
index 3fc750925defe4cd67c26a0a053a73cee0eb4827..324ef24fadd22f2b11572f5331c0fd4a37d2d89f 100644 (file)
@@ -473,13 +473,11 @@ sub refresh () {
        
                                if (exists $depends_simple{$p}) {
                                        foreach my $d (keys %{$depends_simple{$p}}) {
        
                                if (exists $depends_simple{$p}) {
                                        foreach my $d (keys %{$depends_simple{$p}}) {
-                                               if ($depends_simple{$p}{$d} == $IkiWiki::DEPEND_EXISTS) {
-                                                       if (exists $lc_exists_changed{$d}) {
-                                                               $reason = $d;
-                                                               last;
-                                                       }
-                                               }
-                                               elsif (exists $lc_changed{$d}) {
+                                               if (($depends_simple{$p}{$d} & $IkiWiki::DEPEND_CONTENT &&
+                                                    exists $lc_changed{$d})
+                                                   ||
+                                                   ($depends_simple{$p}{$d} & $IkiWiki::DEPEND_PRESENCE &&
+                                                    exists $lc_exists_changed{$d})) {
                                                        $reason = $d;
                                                        last;
                                                }
                                                        $reason = $d;
                                                        last;
                                                }
@@ -492,22 +490,22 @@ sub refresh () {
                                                next if $@ || ! defined $sub;
        
                                                my @candidates;
                                                next if $@ || ! defined $sub;
        
                                                my @candidates;
-                                               if ($depends{$p}{$d} == $IkiWiki::DEPEND_EXISTS) {
-                                                       @candidates=@exists_changed;
-                                               }
-                                               else {
+                                               if ($depends{$p}{$d} & $IkiWiki::DEPEND_CONTENT) {
                                                        @candidates=@changed;
                                                }
                                                        @candidates=@changed;
                                                }
+                                               elsif ($depends{$p}{$d} & $IkiWiki::DEPEND_PRESENCE) {
+                                                       @candidates=@exists_changed;
+                                               }
                                                # only consider internal files
                                                # if the page explicitly depends
                                                # on such files
                                                if ($d =~ /internal\(/) {
                                                # only consider internal files
                                                # if the page explicitly depends
                                                # on such files
                                                if ($d =~ /internal\(/) {
-                                                       if ($depends{$p}{$d} == $IkiWiki::DEPEND_EXISTS) {
-                                                               push @candidates, @internal;
-                                                       }
-                                                       else {
+                                                       if ($depends{$p}{$d} & $IkiWiki::DEPEND_CONTENT) {
                                                                push @candidates, @internal, @internal_change;
                                                        }
                                                                push @candidates, @internal, @internal_change;
                                                        }
+                                                       elsif ($depends{$p}{$d} & $IkiWiki::DEPEND_PRESENCE) {
+                                                               push @candidates, @internal;
+                                                       }
                                                }
        
                                                foreach my $file (@candidates) {
                                                }
        
                                                foreach my $file (@candidates) {