diff --git a/Library/Homebrew/cmd/doctor.rb b/Library/Homebrew/cmd/doctor.rb
index 877b7880ebedc8adeb5e84d491999f6add9c9ef1..61d029d35d51c4b64819eda4472c27e3d2291aab 100644
--- a/Library/Homebrew/cmd/doctor.rb
+++ b/Library/Homebrew/cmd/doctor.rb
@@ -383,13 +383,13 @@ end
 def check_access_logs
   if HOMEBREW_LOGS.exist? and not HOMEBREW_LOGS.writable_real?
     <<-EOS.undent
-      #{folder} isn't writable.
+      #{HOMEBREW_LOGS} isn't writable.
       This can happen if you "sudo make install" software that isn't managed
       by Homebrew.
 
       Homebrew writes debugging logs to this location.
 
-      You should probably `chown` #{folder}
+      You should probably `chown` #{HOMEBREW_LOGS}
     EOS
   end
 end