added template for genserver for apps handling
shitty commit - fixing state