예제 #1
0
        def friends():
            friends = Connection.friendshipRequest("friends",
                                                   {}).get("friends")

            Common.printNotificationText(f"Friends: {len(friends)}")

            for friend in friends:
                Common.printNotificationText(friend)
예제 #2
0
        def outgoing():
            outgoing = Connection.friendshipRequest("outgoing",
                                                    {}).get("outgoing")

            Common.printNotificationText(
                f"Ougoing Friendship Requests: {len(outgoing)}")

            for username in outgoing:
                Common.printNotificationText(username)
예제 #3
0
        def incoming():
            incoming = Connection.friendshipRequest("incoming",
                                                    {}).get("incoming")

            Common.printNotificationText(
                f"Incoming Friendship Requests: {len(incoming)}")

            for username in incoming:
                Common.printNotificationText(username)
예제 #4
0
        def remove():
            username = input("Username -> ")

            response = Connection.friendshipRequest("remove",
                                                    {"username": username})
            successful = response.get("successful")
            message = response.get("message")

            if successful:
                Common.printPositiveText(message)
            else:
                Common.printNegativeText(message)