aboutsummaryrefslogtreecommitdiffhomepage
path: root/application/front/controller/admin/ShaarePublishController.php
diff options
context:
space:
mode:
Diffstat (limited to 'application/front/controller/admin/ShaarePublishController.php')
-rw-r--r--application/front/controller/admin/ShaarePublishController.php13
1 files changed, 8 insertions, 5 deletions
diff --git a/application/front/controller/admin/ShaarePublishController.php b/application/front/controller/admin/ShaarePublishController.php
index 625a5680..4cbfcdc5 100644
--- a/application/front/controller/admin/ShaarePublishController.php
+++ b/application/front/controller/admin/ShaarePublishController.php
@@ -118,7 +118,8 @@ class ShaarePublishController extends ShaarliAdminController
118 $this->container->conf->get('general.tags_separator', ' ') 118 $this->container->conf->get('general.tags_separator', ' ')
119 ); 119 );
120 120
121 if ($this->container->conf->get('thumbnails.mode', Thumbnailer::MODE_NONE) !== Thumbnailer::MODE_NONE 121 if (
122 $this->container->conf->get('thumbnails.mode', Thumbnailer::MODE_NONE) !== Thumbnailer::MODE_NONE
122 && true !== $this->container->conf->get('general.enable_async_metadata', true) 123 && true !== $this->container->conf->get('general.enable_async_metadata', true)
123 && $bookmark->shouldUpdateThumbnail() 124 && $bookmark->shouldUpdateThumbnail()
124 ) { 125 ) {
@@ -148,7 +149,8 @@ class ShaarePublishController extends ShaarliAdminController
148 return $this->redirectFromReferer( 149 return $this->redirectFromReferer(
149 $request, 150 $request,
150 $response, 151 $response,
151 ['/admin/add-shaare', '/admin/shaare'], ['addlink', 'post', 'edit_link'], 152 ['/admin/add-shaare', '/admin/shaare'],
153 ['addlink', 'post', 'edit_link'],
152 $bookmark->getShortUrl() 154 $bookmark->getShortUrl()
153 ); 155 );
154 } 156 }
@@ -168,10 +170,10 @@ class ShaarePublishController extends ShaarliAdminController
168 $this->assignView($key, $value); 170 $this->assignView($key, $value);
169 } 171 }
170 172
171 $editLabel = false === $isNew ? t('Edit') .' ' : ''; 173 $editLabel = false === $isNew ? t('Edit') . ' ' : '';
172 $this->assignView( 174 $this->assignView(
173 'pagetitle', 175 'pagetitle',
174 $editLabel . t('Shaare') .' - '. $this->container->conf->get('general.title', 'Shaarli') 176 $editLabel . t('Shaare') . ' - ' . $this->container->conf->get('general.title', 'Shaarli')
175 ); 177 );
176 178
177 return $response->write($this->render(TemplatePage::EDIT_LINK)); 179 return $response->write($this->render(TemplatePage::EDIT_LINK));
@@ -194,7 +196,8 @@ class ShaarePublishController extends ShaarliAdminController
194 196
195 // If this is an HTTP(S) link, we try go get the page to extract 197 // If this is an HTTP(S) link, we try go get the page to extract
196 // the title (otherwise we will to straight to the edit form.) 198 // the title (otherwise we will to straight to the edit form.)
197 if (true !== $this->container->conf->get('general.enable_async_metadata', true) 199 if (
200 true !== $this->container->conf->get('general.enable_async_metadata', true)
198 && empty($title) 201 && empty($title)
199 && strpos(get_url_scheme($url) ?: '', 'http') !== false 202 && strpos(get_url_scheme($url) ?: '', 'http') !== false
200 ) { 203 ) {