Set undefined vars, remove unused vars nad code that cannot be reached.

pull/427/head
Matthias Gutjahr 9 years ago
parent d56e34f8f5
commit dca8b5555d

@ -33,7 +33,7 @@ class Guest extends Access {
# Error
default: exit('Error: Function not found! Please check the spelling of the called function.');
return false; break;
break;
}
@ -177,4 +177,4 @@ class Guest extends Access {
}
?>
?>

@ -195,7 +195,7 @@ class Album extends Module {
# Execute query
$albums = $this->database->query($query);
if (!$albums) {
Log::error($database, __METHOD__, __LINE__, 'Could not get all albums (' . $database->error . ')');
Log::error($this->database, __METHOD__, __LINE__, 'Could not get all albums (' . $this->database->error . ')');
exit('Error: ' . $this->database->error);
}

@ -277,6 +277,7 @@ if(!defined('LYCHEE')) exit('Error: Direct access is not allowed!');
# This avoids problems with placeholders in user-input
# $skip = Number of placeholders which need to be skipped
$skip = 0;
$temp = '';
$num = array(
'placeholder' => substr_count($query, '?'),
'data' => count($data)

@ -11,7 +11,6 @@ class Import extends Module {
private $database = null;
private $settings = null;
private $albumIDs = null;
public function __construct($database, $plugins, $settings) {

@ -486,8 +486,6 @@ class Photo extends Module {
if (extension_loaded('imagick')&&$this->settings['imagick']==='1') {
$rotateImage = 0;
switch ($info['orientation']) {
case 3:
@ -535,7 +533,6 @@ class Photo extends Module {
break;
case 3:
$process = true;
$sourceImg = imagerotate($sourceImg, -180, 0);
break;
@ -552,7 +549,6 @@ class Photo extends Module {
break;
case 6:
$process = true;
$sourceImg = imagerotate($sourceImg, -90, 0);
$newWidth = $info['height'];
$newHeight = $info['width'];
@ -566,7 +562,6 @@ class Photo extends Module {
break;
case 8:
$process = true;
$sourceImg = imagerotate($sourceImg, 90, 0);
$newWidth = $info['height'];
$newHeight = $info['width'];
@ -1251,4 +1246,4 @@ class Photo extends Module {
}
?>
?>

@ -20,7 +20,6 @@ class Plugins implements \SplSubject {
if (!isset($files)) return false;
# Init vars
$plugins = $this;
$this->files = $files;
# Load plugins
@ -92,4 +91,4 @@ class Plugins implements \SplSubject {
}
?>
?>

Loading…
Cancel
Save