mirror of
https://github.com/xtrll/MusicMetaFinder.git
synced 2026-04-18 00:03:28 +02:00
refactor: remove AuDD references and unused project files
Removed all files, dependencies, and mentions related to the AuDD API. Cleaned up the src directory, removing all non-developed or unused items, as part of a major cleanup. This change is due to the strategic shift towards using audio fingerprinting for song recognition, as opposed to sending the raw audio file itself.
This commit is contained in:
13
src/errors/apiError.js
Normal file
13
src/errors/apiError.js
Normal file
@@ -0,0 +1,13 @@
|
||||
const errorMessages = {
|
||||
NO_DATA: 'No data received',
|
||||
NO_RESPONSE: 'No response received',
|
||||
SETUP_ERROR: 'Error setting up the request',
|
||||
UNKNOWN_ERROR: 'An unknown error occurred',
|
||||
};
|
||||
|
||||
export default function processApiError(error) {
|
||||
let errorMessage = errorMessages[error.code] || errorMessages['UNKNOWN_ERROR'];
|
||||
|
||||
console.error(errorMessage);
|
||||
throw new Error(errorMessage);
|
||||
}
|
||||
Reference in New Issue
Block a user