minor edits, added semicolon. used $log