function findGroupFromExistingGroups(groupname){

    pretty.logWrite("Retrieving the JSON data of ");
    pretty.cPrint(`${groupname}`,"b");

    try{
        const { groups, directory } = require('../static/groups.json');

        const names = groups.map( (group) => { return group["name"] });
        const links = groups.map( (group) => { return group["filename"]});

        if(names.indexOf(groupname) == -1){

            return 18;
        }

        return retrieveGroupMetaData(links[names.indexOf(groupname)], directory);
    }
    catch(err){

        errDict.customError(err);

    }
    
}
/**
 * Observes and retrieves the appropriate location of the group's local JSON data
 * 
 * @param {String} groupname The name of the group translator
 * 
 * @returns returns the URL of the group JSON data
 */
Observes and retrieves the appropriate location of the group's local JSON data

@param {String} groupname The name of the group translator

@returns returns the URL of the group JSON data
Observes and retrieves the appropriate location of the group ' s local JSON data @param { String } groupname The name of the group translator @returns returns the URL of the group JSON data
function findGroupFromExistingGroups(groupname){
    pretty.logWrite("Retrieving the JSON data of ");
    pretty.cPrint(`${groupname}`,"b");
    try{
        const { groups, directory } = require('../static/groups.json');
        const names = groups.map( (group) => { return group["name"] });
        const links = groups.map( (group) => { return group["filename"]});
        if(names.indexOf(groupname) == -1){
            return 18;
        }
        return retrieveGroupMetaData(links[names.indexOf(groupname)], directory);
    }
    catch(err){
        errDict.customError(err);
    }
}
function findGroupFromExistingGroups ( groupname ) { pretty . logWrite ( "Retrieving the JSON data of " ) ; pretty . cPrint ( ` ${ groupname } ` , "b" ) ; try { const { groups , directory } = require ( '../static/groups.json' ) ; const names = groups . map ( ( group ) => { return group [ "name" ] } ) ; const links = groups . map ( ( group ) => { return group [ "filename" ] } ) ; if ( names . indexOf ( groupname ) == - 1 ) { return 18 ; } return retrieveGroupMetaData ( links [ names . indexOf ( groupname ) ] , directory ) ; } catch ( err ) { errDict . customError ( err ) ; } }
Observes and retrieves the appropriate location of the group's local JSON data
Observes and retrieves the appropriate location of the group ' s local JSON data