added activity logging