Title: Some bugs :)
Last modified: August 20, 2016

---

# Some bugs :)

 *  [Joost de Valk](https://wordpress.org/support/users/joostdevalk/)
 * (@joostdevalk)
 * [13 years, 4 months ago](https://wordpress.org/support/topic/some-bugs/)
 * Hey, I ran through the code before I installed the plugin on my site and found
   a few issues. I think none of this will prevent the plugin from working on _my_
   site, but you might want to fix them nonetheless 🙂
    - First of all, in mandrill.class.php, you’re using CURL. Don’t do this. You
      simply cannot rely on CURL being there and WP has its own [HTTP API](http://codex.wordpress.org/HTTP_API)
      which uses whatever transport layer is available, so you should use that.
    - Then, you’re using textdomain wrong, you might want to read [this post](http://markjaquith.wordpress.com/2011/10/06/translating-wordpress-plugins-and-themes-dont-get-clever/)
      by Mark Jaquith. TL;DR: you can’t use a variable for the textdomain as it 
      gets parsed by more than just PHP.
    - The `$dir` variable on line 217 of wpmandrill.php isn’t being used.
    - The same is true for the `$display` variable declared on lines 1062 and 1066
    - The same is true for the `$filter_used` variable declared on lines 1117, 1126
      and 1133
    - The same is true for the `$format_sufix` variable declared on lines 1191, 
      1203, 1435 and 1447
 * [http://wordpress.org/extend/plugins/wpmandrill/](http://wordpress.org/extend/plugins/wpmandrill/)

Viewing 1 replies (of 1 total)

 *  Plugin Author [MC_Will](https://wordpress.org/support/users/mc_will/)
 * (@mc_will)
 * [13 years, 4 months ago](https://wordpress.org/support/topic/some-bugs/#post-3396364)
 * Hello,
 * Thanks a lot for your suggestions!
 * – If the plugin can’t find CURL it tries with fsock* functions. Anyway, we didn’t
   include any WP function in mandrill.class.php because this class is used in more
   than one project, most of them not WP-related. I’ll check if it is being used
   in a WP environment and act accordingly though. Thanks again.
    – Many many thanks
   for the textdomain hint. – Will clean up all those unused variables.
 * All the best,
    Will

Viewing 1 replies (of 1 total)

The topic ‘Some bugs :)’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wpmandrill_171717.svg)
 * [wpMandrill](https://wordpress.org/plugins/wpmandrill/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wpmandrill/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wpmandrill/)
 * [Active Topics](https://wordpress.org/support/plugin/wpmandrill/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wpmandrill/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wpmandrill/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [MC_Will](https://wordpress.org/support/users/mc_will/)
 * Last activity: [13 years, 4 months ago](https://wordpress.org/support/topic/some-bugs/#post-3396364)
 * Status: not resolved