Fixed observer code