store logs in array