Author: dieppe
Date: 2008-04-23 03:16:30 +0000 (Wed, 23 Apr 2008)
New Revision: 19514

Modified:
   trunk/apps/thingamablog/src/net/sf/thingamablog/xml/TBPersistFactory.java
Log:
Fix two bugs : 
- importing weblog created with the upstream;
- importing flog created before we can set the SSKPath (was already fixed, but 
a little change (using ASCIIConv directly in setSSKPath) broke newer versions 
(ASCIIConv doesn't accept null value));

Modified: 
trunk/apps/thingamablog/src/net/sf/thingamablog/xml/TBPersistFactory.java
===================================================================
--- trunk/apps/thingamablog/src/net/sf/thingamablog/xml/TBPersistFactory.java   
2008-04-23 01:44:45 UTC (rev 19513)
+++ trunk/apps/thingamablog/src/net/sf/thingamablog/xml/TBPersistFactory.java   
2008-04-23 03:16:30 UTC (rev 19514)
@@ -603,7 +603,7 @@

                tb.setLocale(createLocale(element.getAttributeValue("locale", 
Locale.getDefault().toString())));
                tb.setPublishAll(element.getAttributeValue("publish_all", 
"true").equals("true"));
-               tb.setType(element.getAttributeValue("type").toString());
+               tb.setType(element.getAttributeValue("type","internet"));

                int arcPolicy = TBWeblog.ARCHIVE_MONTHLY;
                int dayInterval = 5;
@@ -883,9 +883,12 @@
                     if (fcp.getActiveLink()){
                         
fcp.setActiveLinkPath(transport.getAttributeValue("activeLinkPath"));
                     }
-                    fcp.setSSKPath(transport.getAttributeValue("SSKPath"));
-                    if(fcp.getSSKPath() == null)
+                    String SSKPath = transport.getAttributeValue("SSKPath");
+                    if(SSKPath == null) {
                         fcp.setSSKPath(title);                    
+                    } else {
+                        fcp.setSSKPath(SSKPath);
+                    }
                     pubTransport = fcp;
                 }
                else            


Reply via email to