fix conditional in LoadSYSEXFile handleInput

This commit is contained in:
[poww10s]
2020-09-07 18:39:16 -04:00
parent eef5ad0e9e
commit cb255975ee
+1 -5
View File
@@ -110,10 +110,8 @@ function LoadSYSEXFile(props) {
// on submit button press, pass the file to the parent component // on submit button press, pass the file to the parent component
const handleInput = (event) => { const handleInput = (event) => {
if (!fileLoaded()) {
event.preventDefault();
} else {
event.preventDefault(); event.preventDefault();
if (fileLoaded()) {
props.sendFileData(data); props.sendFileData(data);
} }
}; };
@@ -137,8 +135,6 @@ function LoadSYSEXFile(props) {
); );
} }
function fileToObject() {}
function MIDIComponent() { function MIDIComponent() {
const [loadedFile, loadFile] = useState(null); const [loadedFile, loadFile] = useState(null);