Skip to content

Commit c0c924f

Browse files
committed
Merge pull request #444 from electerious/develop
Lychee 3.0.9
2 parents b60f9ed + 7a7ae24 commit c0c924f

23 files changed

Lines changed: 205 additions & 225 deletions

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
dist/**/* binary

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2016 Tobias Reich (http://electerious.com/)
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in
13+
all copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21+
THE SOFTWARE.

README.md

Lines changed: 2 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -64,29 +64,12 @@ Here's a list of all available Plugins and Extensions:
6464
| lychee-watermark | Adds a second watermarked photo when uploading images | [More »](https://github.com/electerious/lychee-watermark) |
6565
| lychee-rss | Creates a RSS-Feed out of your photos | [More »](https://github.com/cternes/Lychee-RSS) |
6666
| lychee-FlashAir | Import from a Toshiba FlashAir WiFi SD card | [More »](https://github.com/mhp/Lychee-FlashAir) |
67+
| lychee-webroot | Controls photos accessibility and keeps Lychee files hidden | [More »](https://github.com/Bramas/lychee-webroot) |
6768

6869
## Troubleshooting
6970

7071
Take a look at the [FAQ](docs/FAQ.md) if you have problems. Discovered a bug? Please create an issue here on GitHub!
7172

72-
## Developer
73-
| Version | Name |
74-
|:-----------|:------------|
75-
| 1.2, 1.3, 2.x, 3.x | [Tobias Reich](http://electerious.com)|
76-
| 1.0, 1.1 | [Tobias Reich](http://electerious.com)<br>[Philipp Maurer](http://phinal.net) |
77-
7873
## Donate
7974

80-
I am working hard on continuously developing and maintaining Lychee. Please consider making a donation via [Flattr](https://flattr.com/submit/auto?user_id=electerious&url=http%3A%2F%2Flychee.electerious.com&title=Lychee&category=software) or PayPal (from [our site](http://lychee.electerious.com/)) to keep the project going strong and me motivated.
81-
82-
## License
83-
84-
(MIT License)
85-
86-
Copyright (C) 2015 [Tobias Reich](http://electerious.com)
87-
88-
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
89-
90-
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
91-
92-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
75+
I am working hard on continuously developing and maintaining Lychee. Please consider making a donation via [Flattr](https://flattr.com/submit/auto?user_id=electerious&url=http%3A%2F%2Flychee.electerious.com&title=Lychee&category=software) or PayPal (from [our site](http://lychee.electerious.com/)) to keep the project going strong and me motivated.

dist/main.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/main.js

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/view.js

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/Changelog.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
1+
## v3.0.9
2+
3+
Released January 10, 2016
4+
5+
- `Improved` Disabled dragging for thumbnails
6+
- `Improved` Avoided unnecessary devicePixelRatio checks by using srcset for all thumbnails
7+
- `Improved` Avoided devicePixelRatio check by using srcset for the imageview image
8+
- `Improved` Don't show log and system information when logged out (Thanks @Bramas, #421)
9+
- `Fixed` Swipe-gestures on mobile devices
10+
111
## v3.0.8
212

313
Released December 20, 2015

docs/Installation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ You can also use the [direct download](https://github.com/electerious/Lychee/arc
2525

2626
### 3. Permissions
2727

28-
Change the permissions of `uploads/`, `data/` and all their subfolders. Sufficient read/write privileges are reqiured.
28+
Change the permissions of `uploads/`, `data/` and all their subfolders. Sufficient read/write privileges are required.
2929

3030
chmod -R 777 uploads/ data/
3131

php/modules/Album.php

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,20 @@ public static function prepareData($data) {
6969
$album['title'] = $data['title'];
7070
$album['public'] = $data['public'];
7171

72+
# Additional attributes
73+
# Only part of $album when available
74+
if (isset($data['description'])) $album['description'] = $data['description'];
75+
if (isset($data['visible'])) $album['visible'] = $data['visible'];
76+
if (isset($data['downloadable'])) $album['downloadable'] = $data['downloadable'];
77+
7278
# Parse date
7379
$album['sysdate'] = date('F Y', $data['sysstamp']);
7480

7581
# Parse password
7682
$album['password'] = ($data['password']=='' ? '0' : '1');
7783

78-
# Set placeholder for thumbs
79-
$album['thumbs'] = array();
84+
# Parse thumbs or set default value
85+
$album['thumbs'] = (isset($data['thumbs']) ? explode(',', $data['thumbs']) : array());
8086

8187
return $album;
8288

@@ -112,8 +118,7 @@ public function get() {
112118
default: $query = Database::prepare($this->database, "SELECT * FROM ? WHERE id = '?' LIMIT 1", array(LYCHEE_TABLE_ALBUMS, $this->albumIDs));
113119
$albums = $this->database->query($query);
114120
$return = $albums->fetch_assoc();
115-
$return['sysdate'] = date('d M. Y', $return['sysstamp']);
116-
$return['password'] = ($return['password']=='' ? '0' : '1');
121+
$return = Album::prepareData($return);
117122
$query = Database::prepare($this->database, "SELECT id, title, tags, public, star, album, thumbUrl, takestamp, url FROM ? WHERE album = '?' " . $this->settings['sortingPhotos'], array(LYCHEE_TABLE_PHOTOS, $this->albumIDs));
118123
break;
119124

plugins/check/index.php

Lines changed: 36 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -103,27 +103,41 @@
103103
echo(PHP_EOL . PHP_EOL . 'System Information' . PHP_EOL);
104104
echo('------------------' . PHP_EOL);
105105

106-
# Load json
107-
$json = file_get_contents(LYCHEE_SRC . 'package.json');
108-
$json = json_decode($json, true);
109-
110-
# About imagick
111-
$imagick = extension_loaded('imagick');
112-
if ($imagick===true) $imagickVersion = @Imagick::getVersion();
113-
else $imagick = '-';
114-
if (!isset($imagickVersion, $imagickVersion['versionNumber'])||$imagickVersion==='') $imagickVersion = '-';
115-
else $imagickVersion = $imagickVersion['versionNumber'];
116-
117-
# Output system information
118-
echo('Lychee Version: ' . $json['version'] . PHP_EOL);
119-
echo('DB Version: ' . $settings['version'] . PHP_EOL);
120-
echo('System: ' . PHP_OS . PHP_EOL);
121-
echo('PHP Version: ' . floatval(phpversion()) . PHP_EOL);
122-
echo('MySQL Version: ' . $database->server_version . PHP_EOL);
123-
echo('Imagick: ' . $imagick . PHP_EOL);
124-
echo('Imagick Active: ' . $settings['imagick'] . PHP_EOL);
125-
echo('Imagick Version: ' . $imagickVersion . PHP_EOL);
126-
echo('GD Version: ' . $gdVersion['GD Version'] . PHP_EOL);
127-
echo('Plugins: ' . $settings['plugins'] . PHP_EOL);
106+
# Ensure that user is logged in
107+
session_start();
108+
109+
if ((isset($_SESSION['login'])&&$_SESSION['login']===true)&&
110+
(isset($_SESSION['identifier'])&&$_SESSION['identifier']===$settings['identifier'])) {
111+
112+
# Load json
113+
$json = file_get_contents(LYCHEE_SRC . 'package.json');
114+
$json = json_decode($json, true);
115+
116+
# About imagick
117+
$imagick = extension_loaded('imagick');
118+
if ($imagick===true) $imagickVersion = @Imagick::getVersion();
119+
else $imagick = '-';
120+
if (!isset($imagickVersion, $imagickVersion['versionNumber'])||$imagickVersion==='') $imagickVersion = '-';
121+
else $imagickVersion = $imagickVersion['versionNumber'];
122+
123+
# Output system information
124+
echo('Lychee Version: ' . $json['version'] . PHP_EOL);
125+
echo('DB Version: ' . $settings['version'] . PHP_EOL);
126+
echo('System: ' . PHP_OS . PHP_EOL);
127+
echo('PHP Version: ' . floatval(phpversion()) . PHP_EOL);
128+
echo('MySQL Version: ' . $database->server_version . PHP_EOL);
129+
echo('Imagick: ' . $imagick . PHP_EOL);
130+
echo('Imagick Active: ' . $settings['imagick'] . PHP_EOL);
131+
echo('Imagick Version: ' . $imagickVersion . PHP_EOL);
132+
echo('GD Version: ' . $gdVersion['GD Version'] . PHP_EOL);
133+
echo('Plugins: ' . $settings['plugins'] . PHP_EOL);
134+
135+
} else {
136+
137+
# Don't go further if the user is not logged in
138+
echo('You have to be logged in to see more information.');
139+
exit();
140+
141+
}
128142

129143
?>

0 commit comments

Comments
 (0)