Upload code cut from the extendify project