Browse Source

Merge pull request #1 from ShaneMcC/master

Small bit of code tidying.
master
Chris Smith 12 years ago
parent
commit
dc227e4a8b
1 changed files with 4 additions and 2 deletions
  1. 4
    2
      FileParser.php

+ 4
- 2
FileParser.php View File

@@ -22,7 +22,9 @@
22 22
 
23 23
     // Close braces
24 24
     if ($tline[0] == '}') {
25
-     call_user_func(array(&$this, 'parse_' . $block), $lines);
25
+     if (method_exists(&$this, 'parse_' . $block)) {
26
+      call_user_func(array(&$this, 'parse_' . $block), $lines);
27
+     }
26 28
      continue;
27 29
     }
28 30
 
@@ -39,6 +41,6 @@
39 41
 
40 42
    $this->analyse();
41 43
   }
42
- } 
44
+ }
43 45
 
44 46
 ?>

Loading…
Cancel
Save