fixed view attach bug with error message 'Attempting to attach...'