Fix State.copy()

This commit is contained in:
Paulus Schoutsen
2015-12-06 09:09:18 -08:00
parent 03962ab6ae
commit f8668075d0
2 changed files with 11 additions and 2 deletions

View File

@@ -381,7 +381,8 @@ class State(object):
def copy(self):
""" Creates a copy of itself. """
return State(self.entity_id, self.state,
dict(self.attributes), self.last_changed)
dict(self.attributes), self.last_changed,
self.last_updated)
def as_dict(self):
""" Converts State to a dict to be used within JSON.