summaryrefslogtreecommitdiffstats
path: root/lib/class/song.class.php
diff options
context:
space:
mode:
authorPaul 'flowerysong' Arthur <flowerysong00@yahoo.com>2010-04-15 21:23:41 +0000
committerPaul 'flowerysong' Arthur <flowerysong00@yahoo.com>2010-04-15 21:23:41 +0000
commit4b4728f0ac8b249a2bd821454079c764198e57ed (patch)
tree1c640fd76a7608db1c1610648d87f7c1368ce998 /lib/class/song.class.php
parent0dc4669407da527bca635342ed6721242ff629ca (diff)
downloadampache-4b4728f0ac8b249a2bd821454079c764198e57ed.tar.gz
ampache-4b4728f0ac8b249a2bd821454079c764198e57ed.tar.bz2
ampache-4b4728f0ac8b249a2bd821454079c764198e57ed.zip
Pad track number with zeros, like the doc says. Fixes FS#58, reported by Adam Grissom.
Diffstat (limited to 'lib/class/song.class.php')
-rw-r--r--lib/class/song.class.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/class/song.class.php b/lib/class/song.class.php
index f376c1dc..ccc9ec4a 100644
--- a/lib/class/song.class.php
+++ b/lib/class/song.class.php
@@ -715,7 +715,7 @@ class Song extends database_object implements media {
/**
* format_pattern
- * This reformates the song information based on the catalog
+ * This reformats the song information based on the catalog
* rename patterns
*/
public function format_pattern() {
@@ -734,7 +734,7 @@ class Song extends database_object implements media {
/* Create the filename that this file should have */
$album = $this->f_album_full;
$artist = $this->f_artist_full;
- $track = $this->track;
+ $track = sprintf('%02d', $this->track);
$title = $this->title;
$year = $this->year;