Skip to content

Commit

Permalink
fix:variable bug (#181)
Browse files Browse the repository at this point in the history
  • Loading branch information
cullenwatson committed Aug 5, 2024
1 parent 209e0e6 commit 0e04643
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "python-jobspy"
version = "1.1.62"
version = "1.1.63"
description = "Job scraper for LinkedIn, Indeed, Glassdoor & ZipRecruiter"
authors = ["Zachary Hampton <[email protected]>", "Cullen Watson <[email protected]>"]
homepage = "https://github.com/Bunsly/JobSpy"
Expand Down
3 changes: 3 additions & 0 deletions src/jobspy/scrapers/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,7 @@ def extract_salary(
if not salary_str:
return None, None, None, None

annual_max_salary = None
min_max_pattern = r"\$(\d+(?:,\d+)?(?:\.\d+)?)([kK]?)\s*[-—–]\s*(?:\$)?(\d+(?:,\d+)?(?:\.\d+)?)([kK]?)"

def to_int(s):
Expand Down Expand Up @@ -238,6 +239,8 @@ def convert_monthly_to_annual(monthly_wage):
annual_max_salary = max_salary

# Ensure salary range is within specified limits
if not annual_max_salary:
return None, None, None, None
if (
lower_limit <= annual_min_salary <= upper_limit
and lower_limit <= annual_max_salary <= upper_limit
Expand Down

0 comments on commit 0e04643

Please sign in to comment.