File tree Expand file tree Collapse file tree 1 file changed +9
-12
lines changed
public_html/wp-content/plugins/wordcamp-reports/classes/report Expand file tree Collapse file tree 1 file changed +9
-12
lines changed Original file line number Diff line number Diff line change @@ -216,25 +216,22 @@ public function get_data() {
216216 }
217217
218218 /**
219- * Get all Meetup posts which have status changed between given time fram
219+ * Get all Meetup posts which have status changed between given time frame.
220220 *
221221 * @return array
222222 */
223223 protected function get_meetup_posts () {
224224 global $ wpdb ;
225225 $ meetup_post_type = WCPT_MEETUP_SLUG ;
226226 $ meetup_post_objs = $ wpdb ->get_results (
227- $ wpdb ->prepare (
228- "
229- SELECT DISTINCT post_id
230- FROM {$ wpdb ->prefix }postmeta
231- WHERE
232- meta_key LIKE '_status_change_log_ $ meetup_post_type%'
233- AND
234- meta_value >= %d
235- AND
236- meta_value <= %d
237- " ,
227+ $ wpdb ->prepare ( "
228+ SELECT DISTINCT post_id
229+ FROM {$ wpdb ->prefix }postmeta
230+ WHERE
231+ meta_key LIKE %s AND
232+ meta_value >= %d AND
233+ meta_value <= %d " ,
234+ sprintf ( '_status_change_log_%s%% ' , $ meetup_post_type ),
238235 $ this ->range ->start ->getTimestamp (),
239236 $ this ->range ->end ->getTimestamp ()
240237 )
You can’t perform that action at this time.
0 commit comments