You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Remove unused Blog properties: rawBlockEditorSettings
Remove unused BlobEntity
Add metadata field to AbstractPost
Add commentsStatus and pingsStatus to Post
Add formattedSize to Media
Testing instructions
I tested the changes with a debugger. The information we need does now get stored in the DB.
Post Metadata
(lldb) po [NSJSONSerialization JSONObjectWithData:post.rawMetadata options:nil error:nil]<__NSArrayI 0x117e27860>({
id =2372;
key ="advanced_seo_description";
value ="";
},{
id =2380;
key = footnotes;
value ="";
},{
id =2373;
key ="jetpack_seo_html_title";
value ="";
},{
id =2374;
key ="jetpack_seo_noindex";
value ="";
},{
id =2347;
key ="wp_jp_foreign_id";
value ="95199E7F-EEF2-46B0-BC89-898AE817CEAD";
},{
id =2377;
key ="_jetpack_dont_email_post_to_subs";
value ="";
},{
id =2376;
key ="_jetpack_newsletter_access";
value = subscribers;
},{
id =2386;
key ="_jetpack_newsletter_tier_id";
value =0;
},{
id =2383;
key ="_wpas_done_all";
value ="";
},{
id =2382;
key ="_wpas_feature_enabled";
value =1;
},{
id =2381;
key ="_wpas_mess";
value ="";
},{
id =2384;
key ="_wpas_options";
value ={"image_generator_settings"={"default_image_id"=0;
enabled =0;
font ="";
template = highway;
};
version =2;
};
})
Discussion Settings
(lldb) po [postPost commentsStatus];
open(lldb) po [postPost pingsStatus];
open
Media Size
(lldb) po remoteMedia.formattedSize
▿1,013.56 KB
- some :"1,013.56 KB"
The reason will be displayed to describe this comment to others. Learn more.
We will now simply store everything, so it'll be easy to add more features that rely on metadata in the future if needed. I also plan to add couple of convenience APIs to make it easier to parse it and find the options you need.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
AbstactPost
properties:metaIsLocal
,metaPublishImmediatelly
,statusAfterSync
,confirmedChangesHash
Blog
properties:rawBlockEditorSettings
BlobEntity
metadata
field toAbstractPost
commentsStatus
andpingsStatus
toPost
formattedSize
toMedia
Testing instructions
I tested the changes with a debugger. The information we need does now get stored in the DB.
Post Metadata
Discussion Settings
Media Size