Bläddra i källkod

Avoid useless warning if purpose was not provided

Alois Mahdal 10 år sedan
förälder
incheckning
1cf703e750
1 ändrade filer med 2 tillägg och 1 borttagningar
  1. 2
    1
      bin/mkexec

+ 2
- 1
bin/mkexec Visa fil

@@ -70,7 +70,8 @@ $cmds->{vim}->{run}     = "vim +\"normal G\$\" '%s'";
70 70
 $cmds->{editor}->{test} = "editor --version 2>/dev/null";
71 71
 $cmds->{editor}->{run}  = "editor '%s'";
72 72
 
73
-unless (exists $templates->{$type}->{$purpose}) {
73
+unless ($purpose eq ""
74
+        or exists $templates->{$type}->{$purpose}) {
74 75
     warn "undefined purpose '$purpose' for type '$type'\n";
75 76
     $purpose = "";
76 77
 }