Skip to content

Commit

Permalink
Do better at setting the order of sections. Fixes #20
Browse files Browse the repository at this point in the history
  • Loading branch information
Bill Hunt committed Feb 19, 2016
1 parent d5956df commit 5688acd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions includes/class.Chicago.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -271,11 +271,11 @@ public function get_section_order_by($code)

public function get_order_by($identifier)
{
$parts = explode('-', $identifier);
$parts = preg_split('/-|\./', $identifier);

foreach($parts as $index => $part)
{
$parts[$index] = str_pad($part, 4, '0', STR_PAD_LEFT);
$parts[$index] = str_pad($part, 3, '0', STR_PAD_LEFT);

}

Expand Down

0 comments on commit 5688acd

Please sign in to comment.