Should the log line be before the `invalidate` call? And should the `invalidate` call have its own log line?