Skip to content

Commit

Permalink
Move comments to the right place
Browse files Browse the repository at this point in the history
  • Loading branch information
iannbing committed May 5, 2022
1 parent b47967b commit b987eb2
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions services/orchest-webserver/client/src/components/DropZone.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,14 @@ import { fetcher, Fetcher, hasValue } from "@orchest/lib-utils";
import React from "react";
import { FileWithPath, useDropzone } from "react-dropzone";

export type FileWithValidPath = FileWithPath & { readonly path: string };

/**
* this function determines if the given file is a file uploaded via useDropzone
* if true, the file has a property "path"
* @param file File | FileWithPath
* @returns boolean
*/

export type FileWithValidPath = FileWithPath & { readonly path: string };

export function isUploadedViaDropzone(
file: File | FileWithPath
): file is FileWithValidPath {
Expand Down

0 comments on commit b987eb2

Please sign in to comment.