Fix typo in debug logic in apm-update