From bc3e2115acfa8e3bb0caa3013a1894ef60aed4d1 Mon Sep 17 00:00:00 2001 From: pieter Date: Thu, 2 Jul 2015 14:12:10 +0200 Subject: [PATCH] Made Contact implement JsonDeserializable. --- telebot/types.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/telebot/types.py b/telebot/types.py index e254fe4..c3c9d90 100644 --- a/telebot/types.py +++ b/telebot/types.py @@ -283,10 +283,10 @@ class Video(JsonDeserializable): self.caption = caption -class Contact: +class Contact(JsonDeserializable): @classmethod def de_json(cls, json_string): - obj = json.loads(json_string) + obj = cls.check_json(json_string) phone_number = obj['phone_number'] first_name = obj['first_name'] last_name = None