The function nodeaccess_nodereference_field_settings() sets basic data for all content types, and full data for a content type that is saved. This is unneccesary, and bloats variable_get().

Is it possible to save the content-type data only if appropriate NANR-settings are made, which are unequal to the default data? Also, unset the data when the default values are re-applied.
This is faster, and makes variable-memory leaner.

Comments

johnv’s picture

Or only saving the non-default values instead of the complete array.

danielb’s picture

I am not convinced it would be faster. Less data in memory, yes, but a lot less - no. And would require more processing when the data is potentially used.

danielb’s picture

The patch in #1619636: Cumulative settings improvements and fixes. seems to have quite minimal changes to when the data is being used, and places the burden on when the data is saved.
Perhaps then this idea is OK.

danielb’s picture

Status: Active » Closed (duplicate)