changed to have it more versitile