From a6999c9609fafa8055f08cc860e6310110a46091 Mon Sep 17 00:00:00 2001 From: Jonny Barnes Date: Thu, 18 May 2017 15:42:06 +0100 Subject: [PATCH 1/4] Need to use sudo for composer self-update --- deploy.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy.sh b/deploy.sh index c16a2e4e..bf25d95d 100755 --- a/deploy.sh +++ b/deploy.sh @@ -4,7 +4,7 @@ echo "Putting the Laravel app in maintenance mode" php artisan down echo "Updating composer and dependencies" -composer self-update +sudo composer self-update composer install echo "Caching Laravel route and config files" From 831d686c64d38f9813374d87a09103b11d9b56e9 Mon Sep 17 00:00:00 2001 From: Jonny Barnes Date: Thu, 18 May 2017 15:59:30 +0100 Subject: [PATCH 2/4] Check for existence of indiewebUser variable --- app/Http/Controllers/MicropubClientController.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/app/Http/Controllers/MicropubClientController.php b/app/Http/Controllers/MicropubClientController.php index 4c97b968..ebe28e14 100644 --- a/app/Http/Controllers/MicropubClientController.php +++ b/app/Http/Controllers/MicropubClientController.php @@ -33,9 +33,11 @@ class MicropubClientController extends Controller if ($url) { $indiewebUser = IndieWebUser::where('me', $url)->first(); } - $syndication = $this->parseSyndicationTargets($indiewebUser->syndication); - $mediaEndpoint = $indiewebUser->mediaEndpoint ?? null; - $mediaURLs = $request->session()->get('media-links'); + if ($indiewebUser) { + $syndication = $this->parseSyndicationTargets($indiewebUser->syndication); + $mediaEndpoint = $indiewebUser->mediaEndpoint ?? null; + $mediaURLs = $request->session()->get('media-links'); + } return view('micropub.create', compact('url', 'syndication', 'mediaEndpoint', 'mediaURLs')); } From 95c84cecbffef2b023a177b7344a8e9bb5cc5991 Mon Sep 17 00:00:00 2001 From: Jonny Barnes Date: Thu, 18 May 2017 16:00:20 +0100 Subject: [PATCH 3/4] Update changelog --- changelog.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/changelog.md b/changelog.md index 780a538d..742233d5 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,8 @@ # Changelog +## Version {next} + - Fix issue on micropub create page when not logged in + ## Version 0.5 (2017-06-18) - Update micropub client to allow indieweb users - Update micropub endpoint to allow for entry updates From 86d948d0871c55c52d8647d9d2b0a9a53a674f7f Mon Sep 17 00:00:00 2001 From: Jonny Barnes Date: Thu, 18 May 2017 16:01:35 +0100 Subject: [PATCH 4/4] Bump version number to 0.5.1 --- changelog.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/changelog.md b/changelog.md index 742233d5..426b8390 100644 --- a/changelog.md +++ b/changelog.md @@ -1,9 +1,9 @@ # Changelog -## Version {next} +## Version 0.5.1 (2017-05-18) - Fix issue on micropub create page when not logged in -## Version 0.5 (2017-06-18) +## Version 0.5 (2017-05-18) - Update micropub client to allow indieweb users - Update micropub endpoint to allow for entry updates - Add support for checkins, so we can use ownyourswarm