fixed a couple syntax issues, added a checker statement to see where a function is defined