fixing realtime updating