diff --git a/templates/channels-page.php b/templates/channels-page.php
index 1bdf11c..edcad7b 100644
--- a/templates/channels-page.php
+++ b/templates/channels-page.php
@@ -19,13 +19,13 @@ if ( current_user_can( 'manage_options' ) ) {
admin->available_channels_callback(); ?>
items[0]->amount; ?>
- name, 'lbrypress' ); ?> |
- |
+ name, 'lbrypress' ); ?> |
+ |
|
|
|
diff --git a/templates/meta-box.php b/templates/meta-box.php
index e577956..af7b819 100644
--- a/templates/meta-box.php
+++ b/templates/meta-box.php
@@ -32,7 +32,12 @@ if ( ( $lbry_published == true ) && ( ( $lbry_claim_id ) ) && ( ! ( $lbry_publis
update_post_meta( $post_id, '_lbry_post_pub_license', $license );
}
$lbry_canonical_url = get_post_meta( $post_id, '_lbry_canonical_url', true );
-$lbry_url = ( ($lbry_canonical_url) ? $lbry_canonical_url : 'lbry://' . $lbry_published_channel . '#' . $lbry_claim_id );
+if ( ! $lbry_canonical_url ) {
+ $result = LBRY()->daemon->claim_search( $lbry_claim_id );
+ $canonical_url = $result->items[0]->canonical_url;
+ update_post_meta( $post_id, '_lbry_canonical_url', $canonical_url );
+}
+$lbry_url = $lbry_canonical_url;
$cur_channel = ( get_post_meta( $post_id, LBRY_POST_PUB_CHANNEL, true ) ? get_post_meta( $post_id, LBRY_POST_PUB_CHANNEL, true ) : get_post_meta( $post_id, '_lbry_channel', true ) );
$default_channel = get_option( LBRY_SETTINGS )['default_lbry_channel'];
$chan_open_url = ( 'open.lbry.com/'. $lbry_published_channel .'#' . $lbry_channel_claim_id . '');
@@ -63,13 +68,13 @@ $chan_open_url = ( 'open.lbry.com/'. $lbry_published_channel .'#' . $lbry_channe
);
printf(
'',
+ ' . esc_html__( '%1$s', 'lbrypress' ) . '' . __( 'Add', 'lbrypress' ) . '',
$support_amount,
- $lbry_claim_id,
- urlencode($lbry_url),
- $lbry_published_channel,
- $support_amount,
- $init_bid
+ urlencode( $lbry_claim_id ),
+ urlencode( esc_url( $lbry_url ) ),
+ urlencode( $lbry_published_channel ),
+ urlencode( $support_amount ),
+ urlencode( $init_bid )
);
printf(
'' . __( 'LBRY channel published to:', 'lbrypress' ) . '