Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Fixed crash when empty object returned from /sendRoleSearchRequest #341

Merged
merged 2 commits into from
Jun 21, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,18 @@ function NoMatchingProfilesResultCard({ role }) {
We will be looking internally for members matching your requirements
and be back at them in about 2 weeks.
</p>
{role && (
{role.rates && role.name ? (
<div styleName="niche-rate-box">
<p>{role.name} Rate</p>
<p styleName="cost">{formatMoney(role.rates[0].global)}</p>
<p>/Week</p>
</div>
) : (
<div styleName="niche-rate-box">
<p>Custom Rate</p>
<p styleName="cost">$1,200</p>
<p>/Week</p>
</div>
)}
<Link to="/taas/myteams/createnewteam">
<Button type="secondary" styleName="button">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ function SearchContainer({
isDisabled={
isCompletenessDisabled ||
searchState === "searching" ||
(searchState === "done" && !matchingRole)
(searchState === "done" && isCustomRole(matchingRole))
}
onClick={searchState ? onSubmit : search}
extraStyleName={completenessStyle}
Expand Down