diff options
| author | Tim Almdal <tnalmdal@shaw.ca> | 2009-02-26 23:38:17 +0000 |
|---|---|---|
| committer | Tim Almdal <tnalmdal@shaw.ca> | 2009-02-26 23:38:17 +0000 |
| commit | d097b4fc027ff558bf5f580298c7bed3696dcd3d (patch) | |
| tree | af67745f12cdb7ebeeff9b615fbf8ec3f5cd6881 /core/helpers/album.php | |
| parent | 960c4248deb43eb824dda14670ea1f759a709013 (diff) | |
Update to image_block based on bharat's feedback
1) move the rand_key column into core
2) don't do a max rand, just try to a get a random number less than
the current random number if that doesn't successd look the other way
Diffstat (limited to 'core/helpers/album.php')
| -rw-r--r-- | core/helpers/album.php | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/helpers/album.php b/core/helpers/album.php index 620d5f14..c75095be 100644 --- a/core/helpers/album.php +++ b/core/helpers/album.php @@ -45,6 +45,7 @@ class album_Core { $album->owner_id = $owner_id; $album->thumb_dirty = 1; $album->resize_dirty = 1; + $album->rand_key = ((float)mt_rand()) / (float)mt_getrandmax(); while (ORM::factory("item") ->where("parent_id", $parent->id) |
