Skip to content

Commit

Permalink
handle jpg format
Browse files Browse the repository at this point in the history
  • Loading branch information
luiserrador committed Oct 18, 2023
1 parent 1f12a5f commit 490b503
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ import React, { Component } from 'react';
const uuid = require('uuid');

function getExtension(filename) {
return filename.split('.').pop()
let ext = filename.split('.').pop()
if (ext === 'jpg') {
return 'jpeg'
} else {
return ext
}
}


Expand Down

0 comments on commit 490b503

Please sign in to comment.