Skip to content
This repository has been archived by the owner on Aug 12, 2024. It is now read-only.

Commit

Permalink
Merge pull request #56 from quintindunn/profile-improvements
Browse files Browse the repository at this point in the history
Fixed hashed_phone_number in generate_profile_object
  • Loading branch information
quintindunn authored Nov 11, 2023
2 parents a5d285d + 37c49c1 commit 976c180
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lapsepy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Date: 10/22/23
"""

__version__ = '1.0.1'
__version__ = '1.0.2'

from .journal import Journal
from .auth.refresher import refresh
Expand Down
2 changes: 1 addition & 1 deletion lapsepy/journal/journal.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ def generate_profile_object(profile_data: dict) -> Profile:
tags=profile_data.get("tags"),
user_id=profile_data.get('id'),
username=profile_data.get('username'),
hashed_phone_number=pd.get("hashedPhoneNumber"),
hashed_phone_number=profile_data.get("hashedPhoneNumber"),
profile_music=profile_music
)

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from setuptools import setup, find_packages

VERSION = "1.0.1"
VERSION = "1.0.2"
DESCRIPTION = "A Python API wrapper for the social media app Lapse."

with open("README.md", 'r') as f:
Expand Down
9 changes: 9 additions & 0 deletions tests/tests_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

lapse = Lapse(os.getenv("LAPSE-TEST-REFRESH"))

test_lapse_profile = lapse.get_current_user()


class TestDOB(TestCase):
def test_modify_dob_year_greater_than_current(self):
Expand Down Expand Up @@ -51,3 +53,10 @@ def test_emojis_n_amount(self):

def test_emojis_text(self):
lapse.update_emojis(["This is a test", "This is also part of the test", "This too", "And this", "Me too!"])


class TestKudos(TestCase):
def test_kudos(self):
uid = test_lapse_profile.user_id
lapse.send_kudos(uid)
lapse.send_kudos(uid)

0 comments on commit 976c180

Please sign in to comment.