Cleaned up indentations and checked all syntax for finalization