exists( $template ) && $wp_filesystem->is_writable( $template ) ) { $contents = $wp_filesystem->get_contents( $template ); $get_post_call_exists = strstr( $contents, 'get_post( $edd_receipt_args[\'id\'] )' ); if ( false === $get_post_call_exists ) { return; } $contents = str_replace( 'get_post( $edd_receipt_args[\'id\'] )', 'edd_get_payment( $edd_receipt_args[\'id\'] )', $contents ); $updated = $wp_filesystem->put_contents( $template, $contents ); // Only display a notice if we could not update the file. if ( ! $updated ) { add_action( 'admin_notices', function() use ( $template ) { ?>

', '' ); ?>