Git Weirdness Fix.
This commit is contained in:
parent
8710f1ee50
commit
edaa788b1c
@ -19,41 +19,23 @@
|
||||
*/
|
||||
class itemchecksum_Controller extends Controller {
|
||||
public function albumcount($album_id) {
|
||||
<<<<<<< HEAD:modules/itemchecksum/controllers/itemchecksum.php
|
||||
// Display the number of non-album items (photos and videos)
|
||||
// in the specified album ($album_id).
|
||||
|
||||
=======
|
||||
>>>>>>> gallery3-contrib/master:modules/itemchecksum/controllers/itemchecksum.php
|
||||
$item = ORM::factory("item")
|
||||
->viewable()
|
||||
->where("parent_id", $album_id)
|
||||
->where("type !=", "album")
|
||||
->find_all();
|
||||
|
||||
|
||||
print count($item);
|
||||
}
|
||||
|
||||
|
||||
public function md5($album_id, $file_name) {
|
||||
<<<<<<< HEAD:modules/itemchecksum/controllers/itemchecksum.php
|
||||
// Locate an item with $file_name in the album $album_id
|
||||
// and display it's md5 checksum.
|
||||
|
||||
=======
|
||||
>>>>>>> gallery3-contrib/master:modules/itemchecksum/controllers/itemchecksum.php
|
||||
$item = ORM::factory("item")
|
||||
->where("parent_id", $album_id)
|
||||
->where("name", $file_name)
|
||||
->find_all();
|
||||
|
||||
|
||||
if (count($item) > 0) {
|
||||
access::required("view_full", $item[0]);
|
||||
<<<<<<< HEAD:modules/itemchecksum/controllers/itemchecksum.php
|
||||
|
||||
// If the KeepOriginal module is active, check for/use the
|
||||
// original image instead of the gallery edited version.
|
||||
=======
|
||||
>>>>>>> gallery3-contrib/master:modules/itemchecksum/controllers/itemchecksum.php
|
||||
if (module::is_active("keeporiginal")) {
|
||||
$original_image = VARPATH . "original/" . str_replace(VARPATH . "albums/", "", $item[0]->file_path());
|
||||
if ($item[0]->is_photo() && file_exists($original_image)) {
|
||||
@ -68,28 +50,16 @@ class itemchecksum_Controller extends Controller {
|
||||
print "0";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public function sha1($album_id, $file_name) {
|
||||
<<<<<<< HEAD:modules/itemchecksum/controllers/itemchecksum.php
|
||||
// Locate an item with $file_name in the album $album_id
|
||||
// and display it's sha-1 checksum.
|
||||
|
||||
=======
|
||||
|
||||
>>>>>>> gallery3-contrib/master:modules/itemchecksum/controllers/itemchecksum.php
|
||||
|
||||
$item = ORM::factory("item")
|
||||
->where("parent_id", $album_id)
|
||||
->where("name", $file_name)
|
||||
->find_all();
|
||||
|
||||
|
||||
if (count($item) > 0) {
|
||||
access::required("view_full", $item[0]);
|
||||
<<<<<<< HEAD:modules/itemchecksum/controllers/itemchecksum.php
|
||||
|
||||
// If the KeepOriginal module is active, check for/use the
|
||||
// original image instead of the gallery edited version.
|
||||
=======
|
||||
>>>>>>> gallery3-contrib/master:modules/itemchecksum/controllers/itemchecksum.php
|
||||
if (module::is_active("keeporiginal")) {
|
||||
$original_image = VARPATH . "original/" . str_replace(VARPATH . "albums/", "", $item[0]->file_path());
|
||||
if ($item[0]->is_photo() && file_exists($original_image)) {
|
||||
@ -104,4 +74,4 @@ class itemchecksum_Controller extends Controller {
|
||||
print "0";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user