Compare commits

..

No commits in common. "279a9f27860aab733eaa592081e040e412d44df5" and "7b154e3a1dbae8896f82c2dbb6a3a333daeadc40" have entirely different histories.

2 changed files with 3 additions and 7 deletions

View File

@ -170,7 +170,7 @@ if __name__ == '__main__':
import_parser.add_argument("--no-create", help="No create post", dest="create", default="store_false", action="store_true") import_parser.add_argument("--no-create", help="No create post", dest="create", default="store_false", action="store_true")
import_parser.add_argument("--no-update", help="No update post", dest="update", default="store_false", action="store_true") import_parser.add_argument("--no-update", help="No update post", dest="update", default="store_false", action="store_true")
import_parser.add_argument("--no-image", help="No image add or update", dest="image", default="store_false", action="store_true") import_parser.add_argument("--no-image", help="No image add or update", dest="image", default="store_false", action="store_true")
import_parser.add_argument("--author", dest="author", help="Define author", default="") import_parser.add_argument("--author-album", dest="author", help="Define author for page album", default="")

View File

@ -237,9 +237,7 @@ class WPimport:
break break
author = self._getInfoAlbum(href_a) author = self._getInfoAlbum(href_a)
self._logger.info("{0} : author : {1}".format(self._name, author)) self._logger.info("{0} : author : {1}".format(self._name, author))
author = self._getAuthor(author) self._getAuthor(author)
data = {"title":albumtitle, "content":content_html, "status":"publish"}
if author != 0: if author != 0:
data = {"title":albumtitle, "content":content_html, "status":"publish", "author":author} data = {"title":albumtitle, "content":content_html, "status":"publish", "author":author}
self._logger.debug("{0} : data for album page : {1}".format(self._name, data)) self._logger.debug("{0} : data for album page : {1}".format(self._name, data))
@ -852,8 +850,6 @@ class WPimport:
title = articletitle[0].text title = articletitle[0].text
author = articleacreator[0].text.lower() author = articleacreator[0].text.lower()
if len(self._author) > 0:
author = self._author
body = articlebody[0].find_all("p") body = articlebody[0].find_all("p")
bodyhtml = "<p>" bodyhtml = "<p>"
for i in body: for i in body: