WordPress.org

Make WordPress Core

Changes between Version 1 and Version 2 of Ticket #49412, comment 4


Ignore:
Timestamp:
02/18/2020 02:35:35 PM (22 months ago)
Author:
johnwatkins0
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #49412, comment 4

    v1 v2  
    6868== Question
    6969
    70 I think the meta key should be carefully considered. I'm using `filesize` because it matches the PHP function and the convention I've seen in plugins and themes that store file size in meta. There's no reason it has to be this, though. If there's a more semantic key -- or perhaps one that is sure to be unique and not conflict with plugins that may hook into attachment metadata -- then it could easily be changed. Any thoughts?
     70The key in the meta array should be carefully considered. I'm using `filesize` because it matches the PHP function and the convention I've seen in plugins and themes that store file size in meta. There's no reason it has to be this, though. If there's a more semantic key -- or perhaps one that is sure to be unique and not conflict with plugins that may hook into attachment metadata -- then it could easily be changed. Any thoughts?