diff options
author | Bharat Mediratta <bharat@menalto.com> | 2011-04-25 22:15:34 -0700 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2011-04-25 22:15:34 -0700 |
commit | 91c83874e518b9106a4d54d8c3bbe28e4c055123 (patch) | |
tree | 1875e7c79ce9350573cd308744a96a1d842a07b8 /modules/gallery/models/item.php | |
parent | 858e3a15b9615d1f0131261310d3ec9846f5e44c (diff) |
Fix a bug introduced in 526859d9605d137ebe053ecbd80f46ca6a331194 where
we changed the behavior of the slug code and included the file
extension, not just the name. This broke
Item_Model_Test::move_photo_with_conflicting_target_gets_uniqified_test
so yay for unit tests! #1668
Diffstat (limited to 'modules/gallery/models/item.php')
-rw-r--r-- | modules/gallery/models/item.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gallery/models/item.php b/modules/gallery/models/item.php index f46db696..2a5e6894 100644 --- a/modules/gallery/models/item.php +++ b/modules/gallery/models/item.php @@ -336,7 +336,7 @@ class Item_Model_Core extends ORM_MPTT { // Make an url friendly slug from the name, if necessary if (empty($this->slug)) { - $this->slug = item::convert_filename_to_slug($this->name); + $this->slug = item::convert_filename_to_slug(pathinfo($this->name, PATHINFO_FILENAME)); // If the filename is all invalid characters, then the slug may be empty here. Pick a // random value. |