The problem with your app is that when someone closes the window, you provide no way to reopen the window. The app ends up in a state where the person using it can't do anything without quitting the app.
The easiest fix is to have your app quit when the app window closes. In the app delegate, write the function applicationShouldTerminateAfterLastWindowClosed() and return true.
func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool {
return true
}
Another possible fix is to remove the Close control from the window so the window can't be closed. Open the storyboard or xib file, select the window, and deselect the Close checkbox in the Attributes Inspector.
Another possible fix is to do what the rejection notice says and add a menu item to reopen the app window. But I don't have any code for you to do that.