Skip to content

Commit

Permalink
fix:keyerror
Browse files Browse the repository at this point in the history
  • Loading branch information
cullenwatson committed Aug 2, 2024
1 parent bd2bb9d commit 57abc73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion staffspy/linkedin/employee.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def parse_emp(self, emp: Staff, emp_dict: dict):

emp.followers = emp_dict.get("followingState", {}).get("followerCount")
emp.connections = emp_dict["connections"]["paging"]["total"]
emp.location = emp_dict.get("geoLocation",{}).get("geo",{}).get("defaultLocalizedName",{})
emp.location = emp_dict.get("geoLocation",{}).get("geo",{}).get("defaultLocalizedName",'')

# Handle empty elements case for company
top_positions = emp_dict.get("profileTopPosition", {}).get("elements", [])
Expand Down

0 comments on commit 57abc73

Please sign in to comment.