Bug: In backend/src/services/job-filter.ts, the US_LOCATION_TOKENS list includes ', in' as a substring match for Indiana. This accidentally matches ', India' on Indian job locations, causing Bangalore/Hyderabad/Mumbai roles to pass the US-only filter.
Same issue likely affects ', or' (Oregon vs. 'and'-like fragments) and ', tn' etc. to a lesser extent.
Scope: Legacy backend pipeline. The MCP server port in mcp-server/src/lib/filter.ts already uses a word-boundary regex to fix this.
Fix for legacy: Replace substring matching for two-letter state abbreviations with a word-boundary regex like /,\s*(ca|ny|...)(?![a-z])/i. Mirror the port.
Bug: In
backend/src/services/job-filter.ts, theUS_LOCATION_TOKENSlist includes', in'as a substring match for Indiana. This accidentally matches', India'on Indian job locations, causing Bangalore/Hyderabad/Mumbai roles to pass the US-only filter.Same issue likely affects
', or'(Oregon vs. 'and'-like fragments) and', tn'etc. to a lesser extent.Scope: Legacy backend pipeline. The MCP server port in
mcp-server/src/lib/filter.tsalready uses a word-boundary regex to fix this.Fix for legacy: Replace substring matching for two-letter state abbreviations with a word-boundary regex like
/,\s*(ca|ny|...)(?![a-z])/i. Mirror the port.