Automattic\WooCommerce\Internal\ProductFeed\Storage
JsonFileFeed::delete
{@inheritDoc}
Метод класса: JsonFileFeed{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$JsonFileFeed = new JsonFileFeed(); $JsonFileFeed->delete( $identifier ): void;
- $identifier(строка) (обязательный)
- The identifier returned by open().
Код JsonFileFeed::delete() JsonFileFeed::delete WC 11.0.1
public function delete( string $identifier ): void {
// Never turn an identifier that is actually a path into a delete outside the feed directory.
if ( ! $this->is_valid_feed_identifier( $identifier ) ) {
return;
}
$path = $this->feed_file_path( $identifier );
if ( is_file( $path ) ) {
wp_delete_file( $path );
}
}