import xhiveframework
from xhiveframework.model.rename_doc import rename_doc


def execute():
	if xhiveframework.db.table_exists("Workflow Action") and not xhiveframework.db.table_exists(
		"Workflow Action Master"
	):
		rename_doc("DocType", "Workflow Action", "Workflow Action Master")
		xhiveframework.reload_doc("workflow", "doctype", "workflow_action_master")
