Skip to content

Simplify #6

@anselmdk

Description

@anselmdk

I've found this module useful for quite a few projects already, however it's unnecessary complicated.

Beyond simplifying the code (which I've taken a stab at in 385dfe4), I'd like the interface to dictate less methods.
Right now it dictates the following:

//Dictated by {@see UploadDirRulesInterface}:
function getCalcAssetsFolderDirectory()
{
    return 'apps';
}
function getMessageSaveFirst()
{
    return null;
}
function getMessageUploadDirectory()
{
    return null;
}
function getReadyForFolderCreation()
{
    return true;
}

I think we could get around with only dictating getCalcAssetsFolderDirectory, and leaving the rest as optional. Actually, getReadyForFolderCreation seems a little obsolete, as it can perfectly be handled by getCalcAssetsFolderDirectory returning something, or false.

Not sure if this would be a best practice.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions