Skip to content

Commit

Permalink
improve install createSymbolicLinks()
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaomlove committed Sep 29, 2023
1 parent 95782ff commit a4e0bc6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions include/constants.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
defined('VERSION_NUMBER') || define('VERSION_NUMBER', '1.8.8');
defined('RELEASE_DATE') || define('RELEASE_DATE', '2023-09-25');
defined('VERSION_NUMBER') || define('VERSION_NUMBER', '1.8.9');
defined('RELEASE_DATE') || define('RELEASE_DATE', '2023-09-29');
defined('IN_TRACKER') || define('IN_TRACKER', false);
defined('PROJECTNAME') || define("PROJECTNAME","NexusPHP");
defined('NEXUSPHPURL') || define("NEXUSPHPURL","https://nexusphp.org");
Expand Down
6 changes: 5 additions & 1 deletion nexus/Install/Install.php
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,11 @@ public function createSymbolicLinks($symbolicLinks)
{
foreach ($symbolicLinks as $path) {
$linkName = ROOT_PATH . 'public/' . basename($path);
if (is_link($linkName)) {
if (is_link($linkName) || is_file($linkName)) {
$delResult = unlink($linkName);
$this->doLog("path: $linkName already exits, try to delete it, delResult: " . var_export($delResult, true));
}
if (is_dir($linkName)) {
$this->doLog("path: $linkName already exits, skip create symbolic link $linkName -> $path");
continue;
}
Expand Down

0 comments on commit a4e0bc6

Please sign in to comment.