Much less stupid way of dealing with missing device