markjaquith / WP-TLC-Transients

GNU General Public License v2.0
341 stars 37 forks source link

Callback question: what to return to NOT overwrite transient #33

Open MickeyKay opened 9 years ago

MickeyKay commented 9 years ago

Question, and forgive me if I'm just missing this in the documentation. My callback involves a wp_remote_get() request and subsequent data checks. If the request fails (e.g. times out), or the data checks don't pass, I don't want to update the transient. Do I just return false? Is there another way to indicate to NOT update the transient?

Thanks!

Rarst commented 9 years ago

There is something with extend_on_fail going, but it's not documented and I don t quite remember what precisely it does. You'll have to read the code. :)