Title: darkcodes's Replies | WordPress.org

---

# darkcodes

  [  ](https://wordpress.org/support/users/darkcodes/)

 *   [Profile](https://wordpress.org/support/users/darkcodes/)
 *   [Topics Started](https://wordpress.org/support/users/darkcodes/topics/)
 *   [Replies Created](https://wordpress.org/support/users/darkcodes/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/darkcodes/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/darkcodes/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/darkcodes/engagements/)
 *   [Favorites](https://wordpress.org/support/users/darkcodes/favorites/)

 Search replies:

## Forum Replies Created

Viewing 1 replies (of 1 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[ACF Color Swatches] Error when returning only the value](https://wordpress.org/support/topic/error-when-returning-only-the-value/)
 *  [darkcodes](https://wordpress.org/support/users/darkcodes/)
 * (@darkcodes)
 * [7 years, 6 months ago](https://wordpress.org/support/topic/error-when-returning-only-the-value/#post-10903767)
 * Here is my solutions
 * At line 399 replace:
 *     ```
       // Replace values which should be returned as transparent
       if (in_array($value['value'], $map_to_transparent)) {
           $value['value'] = 'transparent';
       }
       ```
   
 * With:
 *     ```
       if (is_array($value) && array_key_exists('value', $value)
           && in_array($value['value'], $map_to_transparent)) {
           // Replace values which should be returned as transparent
           $value['value'] = 'transparent';
       } elseif (in_array($value, $map_to_transparent)) {
           $value          = [];
           $value['value'] = 'transparent';
       }
       ```
   

Viewing 1 replies (of 1 total)