Fix for setting CI to device when device is created via API.
Merge pull request #1175 from xor-xor/ci_setter

Fix for setting CI to device when device is created via API.