combine 2 configuration methods into one configure method