def Remove(self,directory,filename):
db = self._loadDB(directory)<EOL>logger.debug("<STR_LIT>"%(filename))<EOL>if db.has_key(filename):<EOL><INDENT>pid=db[filename]<EOL>logger.debug('<STR_LIT>'%(filename,pid))<EOL><DEDENT>else:<EOL><INDENT>print("<STR_LIT>"%(filename,self.DB_FILE))<EOL>return False<EOL><DEDENT>self._connectToWP()<EOL>self.wp.call(DeletePost(pid))<EOL>del db[filename]<EOL>self._saveDB(directory,db)<EOL>return True<EOL>
Deletes post from wordpress