Commits

shl...@b384bcd7-cfd4-0310-aca0-d78b80f7b91b  committed 88c6ccc

Refactored.

  • Participants
  • Parent commits 8556064

Comments (0)

Files changed (1)

File abc-path/Games-ABC_Path-Solver/lib/Games/ABC_Path/Solver/Board.pm

 {
     my ($class, $board_fn) = @_;
 
-    my $self = $class->new;
-
     open my $in_fh, "<", $board_fn
         or die "Cannot open '$board_fn' - $!";
 
     }
     close($in_fh);
 
-    $self->_input({ layout => $layout_string, version => 1});
-
-    return $self;
+    return $class->input_from_v1_string($layout_string);
 }
 
 =head2 my $board = Games::ABC_Path::Solver::Board->input_from_v1_string($layout_string)