Skip to content

Commit

Permalink
refactor: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
miles-grant-ibigroup committed Feb 24, 2023
1 parent a46ca8f commit cf5fdad
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lib/manager/components/validation/GtfsValidationViewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ export default class GtfsValidationViewer extends Component<Props, State> {
{version.mobilityDataResult && version.mobilityDataResult.notices.map(notice => (
<MobilityDataValidationResult notice={notice} />
))}
{!version.mobilityDataResult || version.mobilityDataResult.notices.length === 0 && <ListGroupItem className='validation-item'>
{(!version.mobilityDataResult || version.mobilityDataResult.notices.length === 0) && <ListGroupItem className='validation-item'>
This is the no validation errors message that should only appear if there are none.
</ListGroupItem>}
</ListGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ import { ListGroupItem } from 'react-bootstrap'
import rules from './rules.json'

const MobilityDataValidationResult = (props) => {
const { notice } = props
const rule = rules.find(rd => rd.rule === notice.code)
const { notice } = props
const rule = rules.find(rd => rd.rule === notice.code)

return <ListGroupItem><h4>{notice.code}</h4><p>{rule.description}</p></ListGroupItem>
return <ListGroupItem><h4>{notice.code}</h4><p>{rule.description}</p></ListGroupItem>
}

export default MobilityDataValidationResult
export default MobilityDataValidationResult
2 changes: 1 addition & 1 deletion lib/types/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -539,11 +539,11 @@ export type FeedVersion = FeedVersionSummary & {
fileTimestamp: number,
isCreating?: boolean,
isochrones?: any,
mobilityDataResult: ?any,
nextVersionId: ?string,
noteCount: number,
notes: Array<Note>,
// TODO: Type
mobilityDataResult: ?any,
previousVersionId: ?string,
processedByExternalPublisher: ?number,
sentToExternalPublisher: ?number,
Expand Down

0 comments on commit cf5fdad

Please sign in to comment.