Fix device saving