def insertData(users, channels): db.create_all() ch = Channel() usr = User() ch.getChannelInfo() usr.getUserInformation() ch.sendChannelsToDatabase(True) usr.sendUsersToDatabase(True) db.session.commit()
def main(): ch = Channel() usr = User() channels = ch.getChannelInfo() people = usr.getUserInformation() #messagesForAllChannels = [] #for chan in channels: # mes = getMessageinfo(chan) # messagesForAllChannels.append(mes) insertData(people, channels)