image media_type now have their own config_spec.ini
authorRodney Ewing <ewing.rj@gmail.com>
Wed, 28 Aug 2013 14:56:44 +0000 (07:56 -0700)
committerRodney Ewing <ewing.rj@gmail.com>
Thu, 29 Aug 2013 15:22:16 +0000 (08:22 -0700)
mediagoblin/config_spec.ini
mediagoblin/media_types/image/config_spec.ini [new file with mode: 0644]
mediagoblin/media_types/image/processing.py

index 8f03509d0aed255ae901bd5bdb8ed636608e7e56..790c31a5b6955c22365a9d00769a1269f53b3433 100644 (file)
@@ -104,12 +104,6 @@ max_height = integer(default=640)
 max_width = integer(default=180)
 max_height = integer(default=180)
 
-[media_type:mediagoblin.media_types.image]
-# One of BICUBIC, BILINEAR, NEAREST, ANTIALIAS
-resize_filter = string(default="ANTIALIAS")
-#level of compression used when resizing images
-quality = integer(default=90)
-
 [media_type:mediagoblin.media_types.video]
 # Should we keep the original file?
 keep_original = boolean(default=False)
diff --git a/mediagoblin/media_types/image/config_spec.ini b/mediagoblin/media_types/image/config_spec.ini
new file mode 100644 (file)
index 0000000..08111df
--- /dev/null
@@ -0,0 +1,7 @@
+[plugin_spec]
+# One of BICUBIC, BILINEAR, NEAREST, ANTIALIAS
+resize_filter = string(default="ANTIALIAS")
+#level of compression used when resizing images
+quality = integer(default=90)
+
+
index 088979bc9212fafed4606bb051efd7ef90f554c8..555a0e0a625d25bca6dc0abb8119ebd14c5fec1f 100644 (file)
@@ -138,8 +138,8 @@ class CommonImageProcessor(MediaProcessor):
         """
         Set up the workbench directory and pull down the original file
         """
-        self.image_config = mgg.global_config[
-            'media_type:mediagoblin.media_types.image']
+        self.image_config = mgg.global_config['plugins'][
+            'mediagoblin.media_types.image']
 
         ## @@: Should this be two functions?
         # Conversions subdirectory to avoid collisions