Skip to content

Commit 473623a

Browse files
Merge pull request #866 from LinkStackOrg/beta
Beta
2 parents ad01498 + ee27f6c commit 473623a

File tree

24 files changed

+1938
-13996
lines changed

24 files changed

+1938
-13996
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,8 @@ Before updating, the updater will create a backup. Your instance won’t save mo
205205

206206
If you switched your database to MySQL, your database will not be included in the backup.
207207

208+
The updater may fail without throwing an error and just remain on the current version if there are unmet dependencies. This could include not having the correct version of the dependencies (eg. having php-sqlite3 pointing to php8.3-sqlite3, while LinkStack uses PHP 8.2 and needs php8.2-sqlite3). To troubleshoot, update manually and check the errors thown by the instance when accessing the website, as well as the PHP version reported.
209+
208210
<a name="Discord"></a>
209211
## Discord
210212

app/Http/Controllers/UserController.php

Lines changed: 26 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -753,29 +753,46 @@ public function editTheme(request $request)
753753

754754
if (!empty($zipfile) && Auth::user()->role == 'admin') {
755755

756-
$zipfile->move(base_path('/themes'), "temp.zip");
756+
$themesPath = base_path('themes');
757+
$tmpPath = base_path() . '/themes/temp.zip';
758+
$zipfile->move($themesPath, "temp.zip");
757759

758760
$zip = new ZipArchive;
759-
$zip->open(base_path() . '/themes/temp.zip');
760-
$zip->extractTo(base_path() . '/themes');
761+
$zip->open($tmpPath);
762+
$zip->extractTo($themesPath);
761763
$zip->close();
762-
unlink(base_path() . '/themes/temp.zip');
764+
unlink($tmpPath);
763765

764766
// Removes version numbers from folder.
765767

766-
$folder = base_path('themes');
767768
$regex = '/[0-9.-]/';
768-
$files = scandir($folder);
769+
$files = scandir($themesPath);
770+
$files = array_diff($files, array('.', '..'));
769771

770772
foreach ($files as $file) {
773+
771774
$basename = basename($file);
775+
$filePath = $themesPath . '/' . $basename;
776+
777+
if (!is_dir($filePath)) {
778+
779+
try {
780+
File::delete($filePath);
781+
} catch (exception $e) {}
782+
783+
}
784+
772785
if (preg_match($regex, $basename)) {
786+
773787
$newBasename = preg_replace($regex, '', $basename);
774-
$newPath = $folder . '/' . $newBasename;
775-
File::copyDirectory($file, $newPath);
776-
File::deleteDirectory($file);
788+
$newPath = $themesPath . '/' . $newBasename;
789+
File::copyDirectory($filePath, $newPath);
790+
File::deleteDirectory($filePath);
791+
777792
}
793+
778794
}
795+
779796
}
780797

781798

assets/external-dependencies/fontawesome.css

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

assets/external-dependencies/fontawesome.js

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

assets/linkstack/css/brands.css

Lines changed: 34 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1113,12 +1113,21 @@ button.button-scribd{
11131113

11141114
/* Trakt */
11151115
.button.button-trakt {
1116-
color: #ffffff;
1117-
background-color: #ed1d24;
1118-
}
1119-
.button.button-trakt:hover,
1120-
.button.button-trakt:focus {
1121-
filter: brightness(90%);
1116+
color: white;
1117+
background: radial-gradient(
1118+
farthest-corner at 0% 100%,
1119+
rgb(245, 6, 19) 0%,
1120+
rgb(225, 20, 60) 10%,
1121+
rgb(207, 32, 97) 18%,
1122+
rgb(192, 43, 129) 27%,
1123+
rgb(180, 51, 154) 36%,
1124+
rgb(170, 57, 173) 47%,
1125+
rgb(164, 62, 187) 58%,
1126+
rgb(160, 65, 195) 73%,
1127+
rgb(159, 66, 198) 100%
1128+
);
1129+
background-size: 400% 200%;
1130+
background-position: left bottom;
11221131
}
11231132

11241133
/* Trello */
@@ -1299,3 +1308,22 @@ button.button-scribd{
12991308
.button.button-linkstack:focus {
13001309
filter: brightness(90%);
13011310
}
1311+
/* Xbox */
1312+
.button.button-xbox {
1313+
color: #FFFFFF;
1314+
background-color: #0e7a0d
1315+
;
1316+
}
1317+
.button.button-xbox:hover,
1318+
.button.button-xbox:focus {
1319+
filter: brightness(90%);
1320+
}
1321+
/* Threads */
1322+
.button.button-threads {
1323+
color: #FFFFFF;
1324+
background-color: #000000;
1325+
}
1326+
.button.button-threads:hover,
1327+
.button.button-threads:focus {
1328+
filter: brightness(90%);
1329+
}

assets/linkstack/icons/threads.svg

Lines changed: 1 addition & 0 deletions
Loading

assets/linkstack/icons/trakt.svg

Lines changed: 4 additions & 32 deletions
Loading

assets/linkstack/icons/xbox.svg

Lines changed: 1 addition & 0 deletions
Loading

assets/webfonts/fa-brands-400.ttf

20.6 KB
Binary file not shown.

assets/webfonts/fa-brands-400.woff2

8.71 KB
Binary file not shown.

0 commit comments

Comments
 (0)