X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/d8619a37a078f72f4be154a3b82894810ebebf36..d461d4da5432434916f21b0308c20148210a32f2:/src/validators/require.tsx

diff --git a/src/validators/require.tsx b/src/validators/require.tsx
index 4e1e6629..f636850d 100644
--- a/src/validators/require.tsx
+++ b/src/validators/require.tsx
@@ -4,13 +4,11 @@
 
 export const ERROR_MESSAGE = 'This field is required.';
 
-interface RequireProps {
+interface RequiredProps {
     value: string;
 }
 
 // TODO types for require
-const require: any = (value: string, errorMessage = ERROR_MESSAGE) => {
-    return value && value.toString().length > 0 ? void 0 : ERROR_MESSAGE;
+export const require: any = (value: string) => {
+    return value && value.length > 0 ? undefined : ERROR_MESSAGE;
 };
-
-export default require;
