def save(self, *args, **kwargs):
custom_checks = kwargs.pop('<STR_LIT>', True)<EOL>super(Device, self).save(*args, **kwargs)<EOL>if custom_checks is False:<EOL><INDENT>return<EOL><DEDENT>changed = False<EOL>if not self.location:<EOL><INDENT>self.location = self.node.point<EOL>changed = True<EOL><DEDENT>if not self.elev and self.node.elev:<EOL><INDENT>self.elev = self.node.elev<EOL>changed = True<EOL><DEDENT>original_user = self.shortcuts.get('<STR_LIT:user>')<EOL>if self.node.user:<EOL><INDENT>self.shortcuts['<STR_LIT:user>'] = self.node.user<EOL><DEDENT>if original_user != self.shortcuts.get('<STR_LIT:user>'):<EOL><INDENT>changed = True<EOL><DEDENT>if '<STR_LIT>' in settings.INSTALLED_APPS:<EOL><INDENT>original_layer = self.shortcuts.get('<STR_LIT>')<EOL>self.shortcuts['<STR_LIT>'] = self.node.layer<EOL>if original_layer != self.shortcuts.get('<STR_LIT>'):<EOL><INDENT>changed = True<EOL><DEDENT><DEDENT>if changed:<EOL><INDENT>self.save(custom_checks=False)<EOL><DEDENT>
Custom save method does the following:
    * automatically inherit node coordinates and elevation
    * save shortcuts if HSTORE is enabled