Merge pull request #50 from lemsmyth/rebased-from-lbryio-master
Whitespace & typos
This commit is contained in:
commit
e66bc60c0e
8 changed files with 130 additions and 129 deletions
|
@ -398,7 +398,7 @@ class LBRY_Admin
|
||||||
if (!get_transient('lbry_wallet_warning_email')) {
|
if (!get_transient('lbry_wallet_warning_email')) {
|
||||||
$email = get_option('admin_email');
|
$email = get_option('admin_email');
|
||||||
$subject = 'Your LBRYPress Wallet Balance is Low!';
|
$subject = 'Your LBRYPress Wallet Balance is Low!';
|
||||||
$message = "You LBRY Wallet for your wordpress installation at " . site_url() . " is running very low.\r\n\r\nYou currently have " . $balance . ' LBC left in your wallet. In order to keep publishing to the LBRY network, please add some LBC to your account.';
|
$message = "Your LBRY Wallet for your WordPress installation at " . site_url() . " is running very low.\r\n\r\nYou currently have " . $balance . ' LBC left in your wallet. In order to keep publishing to the LBRY network, please add some LBC to your account.';
|
||||||
wp_mail($email, $subject, $message);
|
wp_mail($email, $subject, $message);
|
||||||
set_transient('lbry_wallet_warning_email', true, DAY_IN_SECONDS);
|
set_transient('lbry_wallet_warning_email', true, DAY_IN_SECONDS);
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
|
|
||||||
class LBRY_Admin_Notice
|
class LBRY_Admin_Notice
|
||||||
{
|
{
|
||||||
|
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
add_action( 'admin_notices', array( $this, 'admin_notices' ) );
|
add_action( 'admin_notices', array( $this, 'admin_notices' ) );
|
||||||
|
|
|
@ -50,8 +50,7 @@ class LBRY_Daemon
|
||||||
* @param int $page Pagination page number
|
* @param int $page Pagination page number
|
||||||
* @return array Array of address lists linked to this account
|
* @return array Array of address lists linked to this account
|
||||||
*/
|
*/
|
||||||
public function address_list($page = 1)
|
public function address_list( $page = 1 ) {
|
||||||
{
|
|
||||||
// Get 20 per page
|
// Get 20 per page
|
||||||
$params = array(
|
$params = array(
|
||||||
'page' => $page,
|
'page' => $page,
|
||||||
|
@ -71,7 +70,7 @@ class LBRY_Daemon
|
||||||
* Returns the available balance of a current LBRY account
|
* Returns the available balance of a current LBRY account
|
||||||
* https://lbry.tech/api/sdk#wallet_balance
|
* https://lbry.tech/api/sdk#wallet_balance
|
||||||
* @param string $address Wallet Address
|
* @param string $address Wallet Address
|
||||||
* @return array $wallet_balance Wallet Balance
|
* @return object $wallet_balance Wallet Balance
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function wallet_balance()
|
public function wallet_balance()
|
||||||
|
@ -114,6 +113,7 @@ class LBRY_Daemon
|
||||||
* https://lbry.tech/api/sdk#channel_create
|
* https://lbry.tech/api/sdk#channel_create
|
||||||
* @return array dictionary containing result of the request
|
* @return array dictionary containing result of the request
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public function channel_new( $channel_name, $channel_bid )
|
public function channel_new( $channel_name, $channel_bid )
|
||||||
{
|
{
|
||||||
// TODO: Sanitize channel name and bid
|
// TODO: Sanitize channel name and bid
|
||||||
|
@ -248,7 +248,7 @@ class LBRY_Daemon
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Checks for erros in decoded daemon response and throws an exception if it finds one
|
* Checks for errors in decoded daemon response and throws an exception if it finds one
|
||||||
* @param $response
|
* @param $response
|
||||||
*/
|
*/
|
||||||
private function check_for_errors( $response )
|
private function check_for_errors( $response )
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
|
|
||||||
class LBRY_Daemon_Logger
|
class LBRY_Daemon_Logger
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The directory to log to
|
* The directory to log to
|
||||||
* @var string
|
* @var string
|
||||||
|
|
|
@ -30,7 +30,7 @@ class LBRY_Network_Publisher
|
||||||
// If everything went well with the conversion, carry on
|
// If everything went well with the conversion, carry on
|
||||||
$args = array(
|
$args = array(
|
||||||
'name' => $post->post_name,
|
'name' => $post->post_name,
|
||||||
'bid' => number_format(floatval(get_option(LBRY_SETTINGS)[LBRY_LBC_PUBLISH]), 2, '.', ''),
|
'bid' => number_format( floatval( get_option( LBRY_SETTINGS )[LBRY_LBC_PUBLISH] ), 3, '.', '' ),
|
||||||
'file_path' => $filepath,
|
'file_path' => $filepath,
|
||||||
'title' => $post->post_title,
|
'title' => $post->post_title,
|
||||||
'languages' => array( substr( get_locale(), 0, 2 ) ),
|
'languages' => array( substr( get_locale(), 0, 2 ) ),
|
||||||
|
|
|
@ -45,4 +45,3 @@ $channel_list = $LBRY->daemon->channel_list();
|
||||||
?>
|
?>
|
||||||
</form>
|
</form>
|
||||||
</div><!-- wrap -->
|
</div><!-- wrap -->
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue