• The JS object model lacks a way to move files from one FileBase to ano

    From Eric Oulashin@VERT to GitLab issue in main/sbbs on Tue Feb 1 18:27:28 2022
    open https://gitlab.synchro.net/main/sbbs/-/issues/333

    As of the 3.19b release of Synchronet, there is a new FileBase class but the JavaScript object model currently lacks a mechanism to move a file from one FileBase to another while preserving all file stats (for example, the file would not retain its last_downloaded, times_downloaded, and other stats).

    Currently, the only way to move a file from one FileBase to another is as follows:

    1. Get the file's metadata object using FileBase.get(filename, FileBase.DETAIL.EXTENDED)
    2. Remove the file from the FileBase using FileBase.remove(filename, false)
    3. Move the file to the other filebase directory (using file_rename()), open that filebase, and use FileBase.Add(meta-data object)

    The metadata object retrieved in step 1 does not include stats such as number of times downloaded, last downloaded, etc., and that information would be lost when moving a file to another filebase.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell@VERT to GitLab note in main/sbbs on Tue Feb 1 18:39:50 2022
    https://gitlab.synchro.net/main/sbbs/-/issues/333#note_2247

    I believe the metadata object retrieved in step 1 *should* include the stats.

    What's lacking is that the FileBase.add() method doesn't parse/use those property value from the file-meta-object passed to it.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell@VERT to GitLab issue in main/sbbs on Tue Feb 1 19:13:45 2022
    close https://gitlab.synchro.net/main/sbbs/-/issues/333

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net