Alert: This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.
EDD_Discount::find_by_code( string $code = '' )
Find a discount in the database with the code supplied.
Description Description
Parameters Parameters
- $code
-
(Optional) Discount code.
Default value: ''
Return Return
(WP_Post) Post instance of the discount.
Source Source
File: includes/class-edd-discount.php
Changelog Changelog
Version | Description |
---|---|
2.7 | Introduced. |