简体   繁体   English

iOS:存档构建的行为与调试构建不同

[英]iOS: Archive build behaves differently then the Debug Build

Note: I am working on a Project which is old and I have to provide the support.注意:我正在处理一个旧项目,我必须提供支持。

Issue : there are few textfield where I have to push view controllers instead of opening the keyboard.问题:我必须推动视图控制器而不是打开键盘的文本字段很少。 So I just implemented the following delegate function所以我只是实现了以下委托 function

func textFieldShouldBeginEditing(_ textField: UITextField) -> Bool {
    // here I am doing my task
    return false
}

It is working perfectly fine, Open the required ViewController when I tap the UITextField but when I make archive and install the build this piece of code does not open the ViewController .它工作得很好,当我点击UITextField时打开所需的ViewController但是当我存档并安装构建时,这段代码不会打开ViewController Instead it opens the keyboard.相反,它会打开键盘。

Any Idea?任何想法?

Check if your project contains lines like检查您的项目是否包含类似的行

#if DEBUG

or或者

#if RELEASE

Looks like the root is here.看起来根在这里。 Not enough information for other assumptions.没有足够的信息来进行其他假设。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM