# Errors when implementing paper

**URL:** https://www.patreondevelopers.com/t/errors-when-implementing-paper/8465
**Category:** Wordpress Plugin
**Created:** [January 4, 2024, 4:08pm UTC](https://www.patreondevelopers.com/t/errors-when-implementing-paper/8465 "2024-01-04T16:08:34Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![shelbykleindesign](https://yyz2.discourse-cdn.com/flex036/user_avatar/www.patreondevelopers.com/shelbykleindesign/32/2525_2.png) [@shelbykleindesign](https://www.patreondevelopers.com/u/shelbykleindesign)
#### Post date: [January 4, 2024, 4:08pm UTC](https://www.patreondevelopers.com/t/errors-when-implementing-paper/8465/1 "2024-01-04T16:08:34Z")

</div>

I’m using this Dropbox paper to implement a way to hide ads for users at $3 or more:

[https://www.dropbox.com/scl/fi/9spl5hqv6d55gb3vxbyru/Patreon-WordPress-how-to-lock-any-part-of-your-Website.paper?rlkey=zr3qdxi5g5sp83c6kbrqc92bt&dl=0](https://www.dropbox.com/scl/fi/9spl5hqv6d55gb3vxbyru/Patreon-WordPress-how-to-lock-any-part-of-your-Website.paper?rlkey=zr3qdxi5g5sp83c6kbrqc92bt&dl=0)

The errors:

> **Warning** : Attempt to read property “ID” on bool in **/nas/content/live/steamdeckhq/wp-content/plugins/patreon-connect/classes/patreon\_wordpress.php** on line **1584**
> 
> **Warning** : Attempt to read property “ID” on bool in **/nas/content/live/steamdeckhq/wp-content/plugins/patreon-connect/classes/patreon\_wordpress.php** on line **1587**
> 
> **Warning** : Attempt to read property “ID” on bool in **/nas/content/live/steamdeckhq/wp-content/plugins/patreon-connect/classes/patreon\_wordpress.php** on line **1584**
> 
> **Warning** : Attempt to read property “ID” on bool in **/nas/content/live/steamdeckhq/wp-content/plugins/patreon-connect/classes/patreon\_wordpress.php** on line **1587**

The code:

```auto
<?php

  $patreon_custom_gate_level = 3; // Replace 7 with the $ value which you want to gate this content with - without the $ sign

  if ( $patreon_gate = Patreon_Frontend::gate_custom_content( $patreon_custom_gate_level ) ) {
      echo $patreon_gate;
  }
  else {
      ?>
         <div id="mediavine-settings" data-blocklist-leaderboard="1" data-blocklist-sidebar-atf="1" data-blocklist-sidebar-btf="1" data-blocklist-content-desktop="1" data-blocklist-content-mobile="1" data-blocklist-adhesion-mobile="1" data-blocklist-adhesion-tablet="1" data-blocklist-adhesion-desktop="1" data-blocklist-recipe="1" data-blocklist-auto-insert-sticky="1" data-blocklist-in-image="1" data-blocklist-chicory="1" data-blocklist-zergnet="1" data-blocklist-interstitial-mobile="1" data-blocklist-interstitial-desktop="1" data-blocklist-universal-player-desktop="1" data-blocklist-universal-player-mobile="1" ></div>
      <?php
  }
        
?>

```

Any idea why this is throwing errors? It doesn’t seem to work at all.

---

<div class="post-metadata">

### Author: ![shelbykleindesign](https://yyz2.discourse-cdn.com/flex036/user_avatar/www.patreondevelopers.com/shelbykleindesign/32/2525_2.png) [@shelbykleindesign](https://www.patreondevelopers.com/u/shelbykleindesign)
#### Post date: [January 4, 2024, 4:47pm UTC](https://www.patreondevelopers.com/t/errors-when-implementing-paper/8465/2 "2024-01-04T16:47:44Z")

</div>

Nevermind, figured it out using this paper instead:

[https://www.dropbox.com/scl/fi/mc2p4rhkvktglex6pdnfh/Patreon-WordPress-How-to-hide-ads-for-patrons.paper?rlkey=ompiqmqlab6giwtoqjt2rye0j&dl=0](https://www.dropbox.com/scl/fi/mc2p4rhkvktglex6pdnfh/Patreon-WordPress-How-to-hide-ads-for-patrons.paper?rlkey=ompiqmqlab6giwtoqjt2rye0j&dl=0)

---

<div class="post-metadata">

### Author: ![codebard](https://yyz2.discourse-cdn.com/flex036/user_avatar/www.patreondevelopers.com/codebard/32/14_2.png) [@codebard](https://www.patreondevelopers.com/u/codebard)
#### Post date: [January 9, 2024, 7:17pm UTC](https://www.patreondevelopers.com/t/errors-when-implementing-paper/8465/3 "2024-01-09T19:17:07Z")

</div>

You may be attempting to get the ID of a user or something on a false return. (likely WP user id). Make a check for the false return if there is one and then try getting the id.
