Skip to content
This repository
Browse code

Fix for tags and complex author urls

  • Loading branch information...
commit 8d639b75730a04af06ce6cc9eb2ba7f4fefcc298 1 parent 58df195
Alessandro Pasotti authored October 05, 2012
2  qgis-app/plugins/tests/HelloWorld/1.5-full-md-no-init-experimental/HelloWorld/metadata.txt
@@ -16,7 +16,7 @@ changelog=this is a very
16 16
     very long multiline changelog
17 17
 
18 18
 
19  
-tags=wkt,raster,hello world
  19
+tags=  wkt, raster,hello world, spaced tag , tag
20 20
 
21 21
 tracker=http://bugs.itopen.it
22 22
 homepage=http://www.itopen.it
4  qgis-app/plugins/views.py
@@ -242,7 +242,7 @@ def plugin_upload(request):
242 242
 
243 243
                 # Takes care of tags
244 244
                 if form.cleaned_data.get('tags'):
245  
-                    plugin.tags.set(*form.cleaned_data.get('tags').split(','))
  245
+                    plugin.tags.set(*[t.strip() for t in form.cleaned_data.get('tags').split(',')])
246 246
 
247 247
                 version_data =  {
248 248
                     'plugin'            : plugin,
@@ -533,7 +533,7 @@ def _main_plugin_update(plugin, form):
533 533
     plugin.email = form.cleaned_data['email']
534 534
     plugin.description = form.cleaned_data['description']
535 535
     if form.cleaned_data.get('tags'):
536  
-        plugin.tags.set(*form.cleaned_data.get('tags').split(','))
  536
+        plugin.tags.set(*[strip(t) for t in form.cleaned_data.get('tags').split(',')])
537 537
     if form.cleaned_data.get('homepage'):
538 538
         plugin.homepage = form.cleaned_data.get('homepage')
539 539
     else:

0 notes on commit 8d639b7

Please sign in to comment.
Something went wrong with that request. Please try again.