more capitalisation, remove debug code

This commit is contained in:
Fox 2026-06-24 12:31:10 +01:00
parent 73cde32638
commit fd46b9c42c
3 changed files with 8 additions and 17 deletions

View File

@ -70,15 +70,7 @@ internal class SolicitorsRepository(IRepoSetupService setup)
else else
await UpdateExistingSolicitorAsync(solicitor, matchingSolicitor, cancellationToken); await UpdateExistingSolicitorAsync(solicitor, matchingSolicitor, cancellationToken);
try await SaveChangesAsync(cancellationToken);
{
await SaveChangesAsync(cancellationToken);
}
catch (Exception e)
{
Console.WriteLine(e);
throw;
}
} }
public Task RemoveStaleEntriesAsync(TimeSpan staleAge, CancellationToken cancellationToken) public Task RemoveStaleEntriesAsync(TimeSpan staleAge, CancellationToken cancellationToken)

View File

@ -24,7 +24,6 @@ export default function Detail(props : DetailProps) {
const [data, setData] = useState<SolicitorInfo | 'loading'>('loading'); const [data, setData] = useState<SolicitorInfo | 'loading'>('loading');
const handleResult = (result : SolicitorInfo | undefined) => { const handleResult = (result : SolicitorInfo | undefined) => {
console.log(data, props, result);
if (data == 'loading' && props.open && props.id == result?.id) { if (data == 'loading' && props.open && props.id == result?.id) {
setData(result); setData(result);
} else if (!result) { } else if (!result) {
@ -40,7 +39,7 @@ export default function Detail(props : DetailProps) {
useEffect(() => { useEffect(() => {
if (props.open && data == 'loading') { if (props.open && data == 'loading') {
getSolicitor(props.id) getSolicitor(props.id)
.then(result => { console.log(result); handleResult(result); }); .then(result => handleResult(result));
} }
}, [props.open]); }, [props.open]);
@ -71,11 +70,12 @@ const style = {
}; };
const DetailDisplay = forwardRef((props : {data : SolicitorInfo | 'loading'}) => { const DetailDisplay = forwardRef((props : {data : SolicitorInfo | 'loading'}) => {
console.log(props.data);
useEffect(() => {console.log(props.data);}, [props.data]);
if (props.data === 'loading') { if (props.data === 'loading') {
return <Box>Nope</Box>; return (
<Box sx={style}>
Nope
</Box>
);
} else { } else {
return ( return (
<Box sx={style}> <Box sx={style}>
@ -89,7 +89,7 @@ const DetailDisplay = forwardRef((props : {data : SolicitorInfo | 'loading'}) =>
{props.data.ratings.map(rating => ( {props.data.ratings.map(rating => (
<Grid size={3}> <Grid size={3}>
<Box sx={{padding: '15px', height: '100%'}}> <Box sx={{padding: '15px', height: '100%'}}>
<Typography variant='body2'>{rating.provider}</Typography> <Typography variant='body2'>{capitaliseFirstLetter(rating.provider)}</Typography>
<Rating <Rating
readOnly readOnly
value={rating.value * 5.0 / rating.maximum} value={rating.value * 5.0 / rating.maximum}

View File

@ -4,7 +4,6 @@ import FilterState from "../models/filterState";
import api from "./axios"; import api from "./axios";
export default async function GetSolicitors(filters : FilterState) { export default async function GetSolicitors(filters : FilterState) {
console.log(api.defaults.baseURL);
var minRating = filters.minRating; var minRating = filters.minRating;
if (minRating == null) { if (minRating == null) {
minRating = 0; minRating = 0;