Title: in_array() expects parameter 2 to be array
Last modified: August 22, 2016

---

# in_array() expects parameter 2 to be array

 *  [RockyMtnHi](https://wordpress.org/support/users/rockymtnhi/)
 * (@rockymtnhi)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/in_array-expects-parameter-2-to-be-array-4/)
 * [03-Mar-2015 04:59:04 UTC] PHP Warning: in_array() expects parameter 2 to be 
   array, boolean given in /home/wildblv0/public_html/wp-content/plugins/yop-poll/
   models/poll_model.php on line 944
 * Can this be fixed?
 * Thanks
 * [https://wordpress.org/plugins/yop-poll/](https://wordpress.org/plugins/yop-poll/)

Viewing 1 replies (of 1 total)

 *  Plugin Author [YOP](https://wordpress.org/support/users/yourownprogrammer/)
 * (@yourownprogrammer)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/in_array-expects-parameter-2-to-be-array-4/#post-5859418)
 * Hello
 * Edit models/poll_model.php and replace
 * `if( in_array( $vote_type, $this->vote_types ) ) {`
 * with
 * `if( $vote_type=='wordpress' || $vote_type=='anonymous' ) {`
 * Best
    YOP Team

Viewing 1 replies (of 1 total)

The topic ‘in_array() expects parameter 2 to be array’ is closed to new replies.

 * ![](https://ps.w.org/yop-poll/assets/icon-256x256.png?rev=3524390)
 * [YOP Poll](https://wordpress.org/plugins/yop-poll/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/yop-poll/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/yop-poll/)
 * [Active Topics](https://wordpress.org/support/plugin/yop-poll/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/yop-poll/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/yop-poll/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [YOP](https://wordpress.org/support/users/yourownprogrammer/)
 * Last activity: [11 years, 2 months ago](https://wordpress.org/support/topic/in_array-expects-parameter-2-to-be-array-4/#post-5859418)
 * Status: not resolved