Skip to content

Commit

Permalink
final biome fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
mrwormhole committed Jul 19, 2024
1 parent b67eb2d commit 69d4612
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
8 changes: 2 additions & 6 deletions src/lib/InvoiceForm.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,7 @@ $: if (browser) {
function setLogo(event: Event) {
const target = event.target as HTMLInputElement;
if (
target.files !== undefined &&
target.files != null &&
target.files.length > 0
) {
if (target.files && target.files.length > 0) {
const file = target.files[0];
if (!validImageTypes.includes(file.type)) {
Expand All @@ -63,7 +59,7 @@ function setLogo(event: Event) {
const reader: FileReader = new FileReader();
reader.onload = () => {
if (reader.result !== undefined && reader.result != null) {
if (reader.result) {
$invoice.logoBase64Img = reader.result.toString();
$invoice.logoFilename = file.name;
}
Expand Down
2 changes: 1 addition & 1 deletion src/lib/InvoicePrint.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ onMount(() => {
</tbody>
</table>

{#if notes.length > 0}
{#if notes.length > 0 && notes.join().trim() != ""}
<div id="notices">
<div><b>NOTES</b></div> <br />
<div class="notice">
Expand Down
4 changes: 2 additions & 2 deletions src/store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ type InvoiceData = {
rows: Array<InvoiceRow>;
currencySymbol: string;
totalAmount: number;
notes: string;

notes: string;
from: string;
to: string;
invoiceNumber: string;
Expand Down

0 comments on commit 69d4612

Please sign in to comment.