diff --git a/app/database/migrations/2014_05_28_071738_update_track_hash.php b/app/database/migrations/2014_05_28_071738_update_track_hash.php new file mode 100644 index 00000000..27dc992a --- /dev/null +++ b/app/database/migrations/2014_05_28_071738_update_track_hash.php @@ -0,0 +1,15 @@ +get() as $track) { + $track->updateHash(); + $track->save(); + } + } + + public function down() { + } +} \ No newline at end of file diff --git a/app/models/Entities/Track.php b/app/models/Entities/Track.php index d0eeb4ec..af063b1e 100644 --- a/app/models/Entities/Track.php +++ b/app/models/Entities/Track.php @@ -420,7 +420,7 @@ } public function updateHash() { - $this->hash = md5(Helpers::sanitizeInputForHashing($this->user->display_name) . '-' . Helpers::sanitizeInputForHashing($this->title)); + $this->hash = md5(Helpers::sanitizeInputForHashing($this->user->display_name) . ' - ' . Helpers::sanitizeInputForHashing($this->title)); } public function updateTags() {