When I tried to build and run, Xcode said my device was locked. I looked at my iPhone, and it\'s not locked at all. How do I fix this?
I have a very simple solution which worked for me instantly. Takes some 10 sec to do:
1) Go to Window -> Devices & Simulators and untick Show as run destination
Window -> Devices & Simulators
Show as run destination
2) Unplug the cable and plug it back in.
3) Run the project.
This should be solving your problem!