Skip to content

Commit

Permalink
Revert 1879cff
Browse files Browse the repository at this point in the history
  • Loading branch information
leandrotoledo committed Nov 10, 2015
1 parent 1879cff commit 5fe1481
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 78 deletions.
1 change: 0 additions & 1 deletion AUTHORS.rst
Expand Up @@ -13,7 +13,6 @@ The following wonderful people contributed directly or indirectly to this projec
- `ErgoZ Riftbit Vaper <https://github.com/ergoz>`_
- `franciscod <https://github.com/franciscod>`_
- `JASON0916 <https://github.com/JASON0916>`_
- `jh0ker <https://github.com/jh0ker>`_
- `JRoot3D <https://github.com/JRoot3D>`_
- `macrojames <https://github.com/macrojames>`_
- `njittam <https://github.com/njittam>`_
Expand Down
33 changes: 0 additions & 33 deletions telegram/emoji.py
Expand Up @@ -20,43 +20,10 @@

"""This module contains a object that represents an Emoji"""

import sys

def call_decode_byte_strings(cls):
"""
Calls the _decode_byte_strings function of the created class
Args:
cls (Class):
Returns:
Class:
"""

cls._decode_byte_strings()
return cls

@call_decode_byte_strings
class Emoji(object):
"""This object represents an Emoji."""

@classmethod
def _decode_byte_strings(cls):
"""
Decodes the Emojis into unicode strings if using Python 3
Args:
cls (Class):
Returns:
"""

if sys.version_info.major is 3:
emojis = filter(lambda attr : type(getattr(cls, attr)) is bytes,
dir(cls))
for var in emojis:
setattr(cls, var, getattr(cls, var).decode('utf-8'))

GRINNING_FACE_WITH_SMILING_EYES = b'\xF0\x9F\x98\x81'
FACE_WITH_TEARS_OF_JOY = b'\xF0\x9F\x98\x82'
SMILING_FACE_WITH_OPEN_MOUTH = b'\xF0\x9F\x98\x83'
Expand Down
44 changes: 0 additions & 44 deletions tests/test_emoji.py

This file was deleted.

0 comments on commit 5fe1481

Please sign in to comment.