Fixed issues with injected dialog