# MeetingChatViewController wrongly assigns keyWindow

**URL:** <https://devforum.zoom.us/t/meetingchatviewcontroller-wrongly-assigns-keywindow/44586>\
**Category:** iOS\
**Created:** [March 2, 2021, 12:48am UTC](https://devforum.zoom.us/t/meetingchatviewcontroller-wrongly-assigns-keywindow/44586 "2021-03-02T00:48:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![caleb.bolton](https://avatars.discourse-cdn.com/v4/letter/c/b38774/32.png) [@caleb.bolton](https://devforum.zoom.us/u/caleb.bolton)\
**Post date:** [March 2, 2021, 12:48am UTC](https://devforum.zoom.us/t/meetingchatviewcontroller-wrongly-assigns-keywindow/44586/1 "2021-03-02T00:48:54Z")

</div>

**Description**  
During a custom UI Zoom meeting the UIApplication’s `keyWindow` is Window instance A. After using `presentMeetingChatViewController:userId` to present the chat view controller, sending a message, and dismissing the VC, the keyWindow is some window instance B, rather than A. This seems like a bug and we had to use a workaround to still use the chat view controller.

**Which Client iOS SDK version?**  
v5.4.54802.0124

**Smartphone (please complete the following information):**

- Device: Xcode Simulator iPad Pro 11 inch 1st gen
- OS: iOS 12.4

---

<div class="post-metadata">

**Author:** ![jon.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/jon.zoom/32/13495_2.png) [@jon.zoom](https://devforum.zoom.us/u/jon.zoom)\
**Post date:** [March 2, 2021, 9:48pm UTC](https://devforum.zoom.us/t/meetingchatviewcontroller-wrongly-assigns-keywindow/44586/2 "2021-03-02T21:48:44Z")

</div>

Hi @caleb.bolton, thanks for the post.

Can you please provide the full code snippet showing how you are calling into this method so that we may investigate?

Thanks!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/6/1/614bdd549b610bbaa46ff934617683a02bdaa03c.png) [@system](https://devforum.zoom.us/u/system)\
**Post date:** [April 2, 2021, 7:49am UTC](https://devforum.zoom.us/t/meetingchatviewcontroller-wrongly-assigns-keywindow/44586/3 "2021-04-02T07:49:15Z")

</div>

Closed on April 2, 2021, 7:49am UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
