heartbeat bugfix