src/indexOld.js
function getSnapshotsKeys(machineName, versionKey, instanceKey){

        let manifest = getManifest();

        let machine = manifest.machines[machineName];
        if (!machine) {
            throw new Error("Machine does not exists");
        }

        let version = machine.versions[versionKey];
        if (!version) {
            throw new Error("Version does not exists");
        }

        let instance = version.instances[instanceKey];
        if (!instance) {
            throw new Error("Instance does not exists");
        }

        return Object.keys(instance.snapshots);
    }
function getSnapshotsKeys(machineName, versionKey, instanceKey){

        let manifest = getManifest();

        let machine = manifest.machines[machineName];
        if (!machine) {
            throw new Error("Machine does not exists");
        }

        let version = machine.versions[versionKey];
        if (!version) {
            throw new Error("Version does not exists");
        }

        let instance = version.instances[instanceKey];
        if (!instance) {
            throw new Error("Instance does not exists");
        }

        return Object.keys(instance.snapshots);
    }
function getSnapshotsKeys ( machineName , versionKey , instanceKey ) { let manifest = getManifest ( ) ; let machine = manifest . machines [ machineName ] ; if ( ! machine ) { throw new Error ( "Machine does not exists" ) ; } let version = machine . versions [ versionKey ] ; if ( ! version ) { throw new Error ( "Version does not exists" ) ; } let instance = version . instances [ instanceKey ] ; if ( ! instance ) { throw new Error ( "Instance does not exists" ) ; } return Object . keys ( instance . snapshots ) ; }
Gets the keys of all of the snapshots of the instance of a version of the machine in the repository
@method getSnapshotsKeys
@param {String} machineName The name of the machine to get the snapshots's keys
@param {String} versionKey The key of the version to get the snapshots's keys
@param {String} instanceKey The key of the instance to get the snapshot's keys
@returns {Array} An array with all the snapshot's keys of the instance
Gets the keys of all of the snapshots of the instance of a version of the machine in the repository