Skip to content

Commit

Permalink
Make use of Inspector::lines instead of file_get_contents
Browse files Browse the repository at this point in the history
  • Loading branch information
mehlah committed Jan 17, 2012
1 parent 423056e commit 17883c0
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions analysis/Inspector.php
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,7 @@ function($str) { return preg_quote($str, '/'); },
$result = array_filter(static::methods($class, 'ranges', $options));

if ($options['filter'] && $class->getFileName()) {
$file = explode("\n", "\n" . file_get_contents($class->getFileName()));
$lines = array_intersect_key($file, array_flip($result));
$lines = static::lines($class->getFileName(), $result);
$start = key($lines);

$code = implode("\n", $lines);
Expand Down

0 comments on commit 17883c0

Please sign in to comment.