[wp-trac] [WordPress Trac] #25542: Function "set_site_transient" is executed twice for plugins - Is it necessary?
WordPress Trac
noreply at wordpress.org
Sat Nov 2 05:36:54 UTC 2013
#25542: Function "set_site_transient" is executed twice for plugins - Is it
necessary?
-------------------------------------------------+-------------------------
Reporter: johnstonphilip | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting
Component: Performance | Review
Severity: trivial | Version: 3.6.1
Keywords: 2nd-opinion needs-testing dev- | Resolution:
feedback |
-------------------------------------------------+-------------------------
Comment (by johnstonphilip):
@dd32 I'm playing with that and it seems to be working. I set the custom
transient to expire after 10 seconds. That way I don't have plugins
staying in the update list for up to an hour after they have been updated.
It isn't the most elegant of solutions but it works.
The only question I'm wondering is if a transient is overkill here. Would
a global "counter" variable be a less intensive option? I could increment
the counter variable and set the wp_remote_post to only fire if the
counter is '2', and then reset it back to 1. Or is that a bad idea?
I appreciate the advice. Thanks guys.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/25542#comment:8>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list