old_contents: import webnotes
  
  def execute():
  	webnotes.reload_doc('website', 'doctype', 'blogger')
  	webnotes.rename_doc("DocType", "Blog", "Blog Post", force=True)
  	webnotes.reload_doc('website', 'doctype', 'blog_post')
  	webnotes.conn.sql('''update tabBlogger set posts=(select count(*) 
  		from `tabBlog Post` where ifnull(blogger,"")=tabBlogger.name)''')
  	webnotes.conn.sql("""update `tabBlog Post` set published_on=creation""")
  
new_contents: import webnotes
  
  def execute():
  	webnotes.reload_doc('website', 'doctype', 'blogger')
  	webnotes.rename_doc("DocType", "Blog", "Blog Post", force=True)
  	webnotes.reload_doc('website', 'doctype', 'blog_post')
  	webnotes.conn.sql('''update tabBlogger set posts=(select count(*) 
  		from `tabBlog Post` where ifnull(blogger,"")=tabBlogger.name)''')
  	webnotes.conn.sql("""update `tabBlog Post` set published_on=date(creation)""")
  
subject: patch fix: published on should be date of creation