struture code a little to check if still works