رفتن به مطلب

Invalid argument supplied for foreach() در افزونه seriously simple podcasting


پست های پیشنهاد شده

با سلام . پس از بروز رسانی افزونه با این ارور Invalid argument supplied for foreach() مواجه شدم . این هم قسمتی که ارور می ده :

 

	public function get_subscribe_urls( $episode_id, $context ) {
		$terms             = get_the_terms( $episode_id, 'series' );
		$subscribe_options = get_option( 'ss_podcasting_subscribe_options', array() );

		$subscribe_array = array();
		foreach ( $subscribe_options as $option_key ) {
			if ( ! isset( $this->available_subscribe_options[ $option_key ] ) ) {
				continue;
			}
			// get the main feed url
			$url = get_option( 'ss_podcasting_' . $option_key . '_url', '' );
			// if we're in a series, and the series has a url for this option
			if ( is_array( $terms ) && isset( $terms[0] ) && false !== get_option( 'ss_podcasting_' . $option_key . '_url_' . $terms[0]->term_id ) ) {
				$url = get_option( 'ss_podcasting_' . $option_key . '_url_' . $terms[0]->term_id, '' );
			}
			$icon                           = str_replace( '_', '-', $option_key );
			$subscribe_array[ $option_key ] = array(
				'key'   => $option_key,
				'url'   => $url,
				'label' => $this->available_subscribe_options[ $option_key ],
				'icon'  => $icon . '.png',
			);
		}

		return apply_filters( 'ssp_episode_subscribe_details', $subscribe_array, $episode_id, $context );

 

لینک به ارسال
  • 3 هفته بعد...

لطفا برای ارسال دیدگاه وارد شوید

شما بعد از اینکه وارد حساب کاربری خود شدید می توانید دیدگاهی ارسال کنید



ورود به حساب کاربری
×
×
  • اضافه کردن...