[CDB] Knowledge Base

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Ideas Centre
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
Locked
User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Thu Mar 30, 2017 11:51 pm

OK, RC1 has been pushed. I've removed the style and language files that were submitted as they will need to be rewrote for RC1. Please test this extension thoroughly (my internal testing on my private board can't catch every scenario).

Style and language authors, you have until June 1 00:00:00 UTC to submit style and language packages for this extension. ;)
Image

ansysko
Registered User
Posts: 55
Joined: Wed Feb 03, 2010 4:03 pm

Re: [3.2][RC] Knowledge Base

Post by ansysko » Sat Apr 01, 2017 12:06 am

Hi here is Slovak translation for [RC] 1.0.0
knowledgebase-1.0.0-RC1_sk.zip

User avatar
Froddelaar
Registered User
Posts: 483
Joined: Tue Mar 29, 2016 3:45 am
Location: Aalst (Belgium)
Name: Andy Dm
Contact:

Re: [3.2][RC] Knowledge Base

Post by Froddelaar » Sat Apr 01, 2017 1:21 pm

I'm A Stupid F*ck.. And Proud Of it!
Download +34.000 arcade extension games @ ~ https://www.froddelpower.be ~

Dutch Extension Translations @ https://github.com/Solidjeuh
Donations are always welcome @ https://www.froddelpower.be/donation

newbeetle91
Registered User
Posts: 16
Joined: Sun May 21, 2006 6:15 pm
Name: Philippe
Contact:

Re: [3.2][RC] Knowledge Base

Post by newbeetle91 » Sun Apr 02, 2017 9:28 am

Hi, ;)

I am finishing the French translation but I have a doubt on:

Code: Select all

'ACP_CATEGORY_DESCRIPTION_EXPLAIN'			=> 'The category description is displayed on the viewcategory page for the category.',
I did not find any way to display viewcategory page :?:

User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Sun Apr 02, 2017 2:11 pm

newbeetle91 wrote:
Sun Apr 02, 2017 9:28 am
Hi, ;)

I am finishing the French translation but I have a doubt on:

Code: Select all

'ACP_CATEGORY_DESCRIPTION_EXPLAIN'			=> 'The category description is displayed on the viewcategory page for the category.',
I did not find any way to display viewcategory page :?:
Ah, you're right - that's an unused language string. A change was made where selecting a category still used the index page. Give me a minute to think about how I want to address it, because I think having the description displayed would be beneficial. For now, include that line in the language package.

Edit: I made a change where descriptions will show on the index page if a category is selected. Everyone please update your language files to change the above mentioned line to this:

Code: Select all

'ACP_CATEGORY_DESCRIPTION_EXPLAIN'			=> 'The category description is displayed on the index page when a category is selected.',
Image

User avatar
eunaumtenhoid
Registered User
Posts: 518
Joined: Wed Jun 03, 2009 12:46 am
Location: ????

Re: [3.2][RC] Knowledge Base

Post by eunaumtenhoid » Fri Apr 07, 2017 12:40 pm

WOW congratulation my friend
i ll test

ty
My translations of the extensions for Brazilian Portuguese
https://github.com/eunaumtenhoid/Traducoesbrphpbb

User avatar
eqsanctum
Registered User
Posts: 31
Joined: Sun Apr 06, 2003 10:00 pm
Contact:

Re: [3.2][RC] Knowledge Base

Post by eqsanctum » Thu Apr 13, 2017 6:41 pm

Something went wrong during the request and an exception was thrown. The changes made before the error occurred were reversed to the best of our abilities, but you should check the board for errors.
The permission role "ROLE_MOD_STANDARD" unexpectedly does not exist.

Something to point out.

On my board, which I'm sure was something you weren't prepared for, the permission role doesn't exist. This is something to be aware of. People like myself might not have the standard roles, or groups, available to auto assign to the install of the extension.

So, currently, there is now way for me to test or even on release, use the extension, because it relies on a permission role that does not exist on my install, because I removed it a long time ago.

User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Fri Apr 14, 2017 12:26 am

Yeah, users generally don't remove the default roles, but it's your board and can do what you please. It's easy to fix too.

OPEN: /migrations/v10x/release_0_0_1.php

FIND:

Code: Select all

array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_edit')),
array('permission.permission_set', array('ROLE_MOD_STANDARD', 'm_kb_edit')),
array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_delete')),
array('permission.permission_set', array('ROLE_MOD_STANDARD', 'm_kb_delete')),
array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_approve')),
array('permission.permission_set', array('ROLE_MOD_STANDARD', 'm_kb_approve')),
array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_chgposter')),
array('permission.permission_set', array('ROLE_MOD_STANDARD', 'm_kb_chgposter')),
REPLACE WITH:

Code: Select all

array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_edit')),
array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_delete')),
array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_approve')),
array('permission.permission_set', array('ROLE_MOD_FULL', 'm_kb_chgposter')),
I'm sure there's a way to check if a role exists - I'll look into that. Thanks!
Image

User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Sat Apr 15, 2017 1:38 am

The issue referenced above has been fixed and pushed to the repository.
Image

User avatar
eqsanctum
Registered User
Posts: 31
Joined: Sun Apr 06, 2003 10:00 pm
Contact:

Re: [3.2][RC] Knowledge Base

Post by eqsanctum » Sat Apr 15, 2017 3:18 am

Well ill check it out. Thank you for being on top of things. I have to assume this is a unique situation. Thank you for taking the time to find a fix that is compatible for folks that don't follow the cookie cutter lifestyle :lol:

Edit:

Ok, throwing me a 500 server error, had to pull all files except for json to even access admin panel:

Running 5.5, pretty sure I have all the permissions set correctly, I do not recognize that type of 500 fail.

================ Thu, 30 Mar 2017 12:36:01 -0500 ==============
946500 20 0 290m 24m 10m R 9.6 0.1 0:00.05 /usr/bin/php
eqsanctum.com/index.php

Code: Select all

Fatal error: Uncaught exception 'Symfony\Component\DependencyInjection\Exception\RuntimeException' with message 
'The parent definition "notification.type.base" defined for definition 
"kinerity.knowledgebase.notification.type.article_in_queue" does not exist.' in 
/home/sargeras/public_html/eqsanctum.com/vendor/symfony/dependency-
injection/Compiler/ResolveDefinitionTemplatesPass.php:100 Stack trace: #0 
/home/sargeras/public_html/eqsanctum.com/vendor/symfony/dependency-
injection/Compiler/ResolveDefinitionTemplatesPass.php(67): 
Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass-
>resolveDefinition(Object(Symfony\Component\DependencyInjection\ContainerBuilder), 
Object(Symfony\Component\DependencyInjection\DefinitionDecorator)) #1 
/home/sargeras/public_html/eqsanctum.com/vendor/symfony/dependency-
injection/Compiler/ResolveDefinitionTemplatesPass.php(42): 
Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass-
>resolveArguments(Object(Symfony\Component\DependencyInjection\Container in 
/home/sargeras/public_html/eqsanctum.com/vendor/symfony/dependency-
injection/Compiler/ResolveDefinitionTemplatesPass.php on line 100

User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Sat Apr 15, 2017 3:29 pm

Are you sure the \phpbb\notification\type\base file exists?

class article_in_queue extends \phpbb\notification\type\base
Image

User avatar
eqsanctum
Registered User
Posts: 31
Joined: Sun Apr 06, 2003 10:00 pm
Contact:

Re: [3.2][RC] Knowledge Base

Post by eqsanctum » Sun Apr 16, 2017 10:37 am

kinerity wrote:
Sat Apr 15, 2017 3:29 pm
Are you sure the \phpbb\notification\type\base file exists?

class article_in_queue extends \phpbb\notification\type\base
Fatal error: Uncaught exception 'Symfony\Component\DependencyInjection\Exception\RuntimeException' with message
'The parent definition "notification.type.base" defined for definition
"kinerity.knowledgebase.notification.type.article_in_queue" does not exist.' in
/home/sargeras/public_html/eqsanctum.com/vendor/symfony/dependency-
injection/Compiler/ResolveDefinitionTemplatesPass.php:100

both the template file and the base file exist.

User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Sun Apr 16, 2017 10:52 pm

I can't reproduce this. Can you give more information about your environment?
Image

User avatar
eqsanctum
Registered User
Posts: 31
Joined: Sun Apr 06, 2003 10:00 pm
Contact:

Re: [3.2][RC] Knowledge Base

Post by eqsanctum » Mon Apr 17, 2017 4:11 pm

kinerity wrote:
Sun Apr 16, 2017 10:52 pm
I can't reproduce this. Can you give more information about your environment?
Let me make sure my upgrade went like it was supposed to. I'm going to ask for advice fixing the error phpbb side first. I hope it's just a missing or obsolete file.

Edit: The reason I am saying this, I was one of those people that had upgrade issues initially. I still have to tweak the system to run on 7 rather than 5.5/6 etc. So let me make sure it's not on my end. I know the file exists but it did in 3.1 as well.

This is the contents of my base.php file

Code: Select all

<?php
/**
*
* This file is part of the phpBB Forum Software package.
*
* @copyright (c) phpBB Limited <https://www.phpbb.com>
* @license GNU General Public License, version 2 (GPL-2.0)
*
* For full copyright and license information, please see
* the docs/CREDITS.txt file.
*
*/

namespace phpbb\notification\type;

/**
* Base notifications class
*/
abstract class base implements \phpbb\notification\type\type_interface
{
	/** @var \phpbb\notification\manager */
	protected $notification_manager;

	/** @var \phpbb\user_loader */
	protected $user_loader;

	/** @var \phpbb\db\driver\driver_interface */
	protected $db;

	/** @var \phpbb\cache\driver\driver_interface */
	protected $cache;

	/** @var \phpbb\template\template */
	protected $template;

	/** @var \phpbb\user */
	protected $user;

	/** @var \phpbb\auth\auth */
	protected $auth;

	/** @var \phpbb\config\config */
	protected $config;

	/** @var string */
	protected $phpbb_root_path;

	/** @var string */
	protected $php_ext;

	/** @var string */
	protected $notification_types_table;

	/** @var string */
	protected $notifications_table;

	/** @var string */
	protected $user_notifications_table;

	/**
	* Notification option data (for outputting to the user)
	*
	* @var bool|array False if the service should use its default data
	* 					Array of data (including keys 'id', 'lang', and 'group')
	*/
	public static $notification_option = false;

	/**
	* The notification_type_id, set upon creation of the class
	* This is the notification_type_id from the notification_types table
	*
	* @var int
	*/
	protected $notification_type_id;

	/**
	* Indentification data
	* notification_type_id	- ID of the item type (auto generated, from notification types table)
	* item_id				- ID of the item (e.g. post_id, msg_id)
	* item_parent_id		- Parent item id (ex: for topic => forum_id, for post => topic_id, etc)
	* user_id
	* notification_read
	* notification_time
	* notification_data (special serialized field that each notification type can use to store stuff)
	*
	* @var array $data Notification row from the database
	* 		This must be private, all interaction should use __get(), __set(), get_data(), set_data()
	*/
	private $data = array();

	/**
	* Notification Type Base Constructor
	*
	* @param \phpbb\user_loader $user_loader
	* @param \phpbb\db\driver\driver_interface $db
	* @param \phpbb\cache\driver\driver_interface $cache
	* @param \phpbb\user $user
	* @param \phpbb\auth\auth $auth
	* @param \phpbb\config\config $config
	* @param string $phpbb_root_path
	* @param string $php_ext
	* @param string $notification_types_table
	* @param string $notifications_table
	* @param string $user_notifications_table
	* @return \phpbb\notification\type\base
	*/
	public function __construct(\phpbb\user_loader $user_loader, \phpbb\db\driver\driver_interface $db, \phpbb\cache\driver\driver_interface $cache, $user, \phpbb\auth\auth $auth, \phpbb\config\config $config, $phpbb_root_path, $php_ext, $notification_types_table, $notifications_table, $user_notifications_table)
	{
		$this->user_loader = $user_loader;
		$this->db = $db;
		$this->cache = $cache;
		$this->user = $user;
		$this->auth = $auth;
		$this->config = $config;

		$this->phpbb_root_path = $phpbb_root_path;
		$this->php_ext = $php_ext;

		$this->notification_types_table = $notification_types_table;
		$this->notifications_table = $notifications_table;
		$this->user_notifications_table = $user_notifications_table;
	}

	/**
	* Set notification manager (required)
	*
	* @param \phpbb\notification\manager $notification_manager
	*/
	public function set_notification_manager(\phpbb\notification\manager $notification_manager)
	{
		$this->notification_manager = $notification_manager;

		$this->notification_type_id = $this->notification_manager->get_notification_type_id($this->get_type());
	}

	/**
	* Set initial data from the database
	*
	* @param array $data Row directly from the database
	*/
	public function set_initial_data($data = array())
	{
		// The row from the database (unless this is a new notification we're going to add)
		$this->data = $data;
		$this->data['notification_data'] = (isset($this->data['notification_data'])) ? unserialize($this->data['notification_data']) : array();
	}

	/**
	* Magic method to get data from this notification
	*
	* @param mixed $name
	* @return mixed
	*/
	public function __get($name)
	{
		return (!isset($this->data[$name])) ? null : $this->data[$name];
	}


	/**
	* Magic method to set data on this notification
	*
	* @param mixed $name
	* @param mixed $value
	*
	* @return null
	*/
	public function __set($name, $value)
	{
		$this->data[$name] = $value;
	}


	/**
	* Magic method to get a string of this notification
	*
	* Primarily for testing
	*
	* @return mixed
	*/
	public function __toString()
	{
		return (!empty($this->data)) ? var_export($this->data, true) : $this->get_type();
	}

	/**
	* Get special data (only important for the classes that extend this)
	*
	* @param string $name Name of the variable to get
	* @return mixed
	*/
	protected function get_data($name)
	{
		return ($name === false) ? $this->data['notification_data'] : ((isset($this->data['notification_data'][$name])) ? $this->data['notification_data'][$name] : null);
	}

	/**
	* Set special data (only important for the classes that extend this)
	*
	* @param string $name Name of the variable to set
	* @param mixed $value Value to set to the variable
	* @return mixed
	*/
	protected function set_data($name, $value)
	{
		$this->data['notification_data'][$name] = $value;
	}

	/**
	* Function for preparing the data for insertion in an SQL query
	* (The service handles insertion)
	*
	* @param array $type_data Data unique to this notification type
	* @param array $pre_create_data Data from pre_create_insert_array()
	* @return array Array of data ready to be inserted into the database
	*/
	public function create_insert_array($type_data, $pre_create_data = array())
	{
		// Defaults
		$this->data = array_merge(array(
			'item_id'				=> static::get_item_id($type_data),
			'notification_type_id'	=> $this->notification_type_id,
			'item_parent_id'		=> static::get_item_parent_id($type_data),

			'notification_time'		=> time(),
			'notification_read'		=> false,

			'notification_data'					=> array(),
		), $this->data);

		$data = $this->data;

		$data['notification_data'] = serialize($data['notification_data']);

		return $data;
	}

	/**
	* Function for preparing the data for update in an SQL query
	* (The service handles insertion)
	*
	* @param array $type_data Data unique to this notification type
	* @return array Array of data ready to be updated in the database
	*/
	public function create_update_array($type_data)
	{
		$data = $this->create_insert_array($type_data);

		// Unset data unique to each row
		unset(
			$data['notification_time'], // Also unsetting time, since it always tries to change the time to current (if you actually need to change the time, over-ride this function)
			$data['notification_id'],
			$data['notification_read'],
			$data['user_id']
		);

		return $data;
	}

	/**
	* Mark this item read
	*
	* @param bool $return True to return a string containing the SQL code to update this item, False to execute it (Default: False)
	* @return string|null If $return is False, nothing will be returned, else the sql code to update this item
	*/
	public function mark_read($return = false)
	{
		return $this->mark(false, $return);
	}

	/**
	* Mark this item unread
	*
	* @param bool $return True to return a string containing the SQL code to update this item, False to execute it (Default: False)
	* @return string|null If $return is False, nothing will be returned, else the sql code to update this item
	*/
	public function mark_unread($return = false)
	{
		return $this->mark(true, $return);
	}

	/**
	* {inheritDoc}
	*/
	public function get_redirect_url()
	{
		return $this->get_url();
	}

	/**
	* Prepare to output the notification to the template
	*
	* @return array Template variables
	*/
	public function prepare_for_display()
	{
		$mark_hash = generate_link_hash('mark_notification_read');

		if ($this->get_url())
		{
			$u_mark_read = append_sid($this->phpbb_root_path . 'index.' . $this->php_ext, 'mark_notification=' . $this->notification_id . '&amp;hash=' . $mark_hash);
		}
		else
		{
			$redirect = (($this->user->page['page_dir']) ? $this->user->page['page_dir'] . '/' : '') . $this->user->page['page_name'] . (($this->user->page['query_string']) ? '?' . $this->user->page['query_string'] : '');

			$u_mark_read = append_sid($this->phpbb_root_path . 'index.' . $this->php_ext, 'mark_notification=' . $this->notification_id . '&amp;hash=' . $mark_hash . '&amp;redirect=' . urlencode($redirect));
		}

		return array(
			'NOTIFICATION_ID'	=> $this->notification_id,
			'STYLING'			=> $this->get_style_class(),
			'AVATAR'			=> $this->get_avatar(),
			'FORMATTED_TITLE'	=> $this->get_title(),
			'REFERENCE'			=> $this->get_reference(),
			'FORUM'				=> $this->get_forum(),
			'REASON'			=> $this->get_reason(),
			'URL'				=> $this->get_url(),
			'TIME'	   			=> $this->user->format_date($this->notification_time),
			'UNREAD'			=> !$this->notification_read,
			'U_MARK_READ'		=> (!$this->notification_read) ? $u_mark_read : '',
		);
	}

	/**
	* -------------- Fall back functions -------------------
	*/

	/**
	* URL to unsubscribe to this notification (fall back)
	*
	* @param string|bool $method Method name to unsubscribe from (email|jabber|etc), False to unsubscribe from all notifications for this item
	*/
	public function get_unsubscribe_url($method = false)
	{
		return false;
	}

	/**
	* Get the CSS style class of the notification (fall back)
	*
	* @return string
	*/
	public function get_style_class()
	{
		return '';
	}

	/**
	* Get the user's avatar (fall back)
	*
	* @return string
	*/
	public function get_avatar()
	{
		return '';
	}

	/**
	* Get the reference of the notifcation (fall back)
	*
	* @return string
	*/
	public function get_reference()
	{
		return '';
	}

	/**
	* Get the forum of the notification reference (fall back)
	*
	* @return string
	*/
	public function get_forum()
	{
		return '';
	}

	/**
	* Get the reason for the notifcation (fall back)
	*
	* @return string
	*/
	public function get_reason()
	{
		return '';
	}

	/**
	* Get the special items to load (fall back)
	*
	* @return array
	*/
	public function get_load_special()
	{
		return array();
	}

	/**
	* Load the special items (fall back)
	*/
	public function load_special($data, $notifications)
	{
		return;
	}

	/**
	* Is available (fall back)
	*
	* @return bool
	*/
	public function is_available()
	{
		return true;
	}

	/**
	* Pre create insert array function (fall back)
	*
	* @return array
	*/
	public function pre_create_insert_array($type_data, $notify_users)
	{
		return array();
	}

	/**
	* -------------- Helper functions -------------------
	*/

	/**
	* Find the users who want to receive notifications (helper)
	*
	* @param array $user_ids User IDs to check if they want to receive notifications
	* 		(Bool False to check all users besides anonymous and bots (USER_IGNORE))
	*
	* @return array
	*/
	protected function check_user_notification_options($user_ids = false, $options = array())
	{
		$options = array_merge(array(
			'ignore_users'		=> array(),
			'item_type'			=> $this->get_type(),
			'item_id'			=> 0, // Global by default
		), $options);

		if ($user_ids === false)
		{
			$user_ids = array();

			$sql = 'SELECT user_id
				FROM ' . USERS_TABLE . '
				WHERE user_id <> ' . ANONYMOUS . '
					AND user_type <> ' . USER_IGNORE;
			$result = $this->db->sql_query($sql);
			while ($row = $this->db->sql_fetchrow($result))
			{
				$user_ids[] = $row['user_id'];
			}
			$this->db->sql_freeresult($result);
		}

		if (empty($user_ids))
		{
			return array();
		}

		$rowset = $resulting_user_ids = array();

		$sql = 'SELECT user_id, method, notify
			FROM ' . $this->user_notifications_table . '
			WHERE ' . $this->db->sql_in_set('user_id', $user_ids) . "
				AND item_type = '" . $this->db->sql_escape($options['item_type']) . "'
				AND item_id = " . (int) $options['item_id'];
		$result = $this->db->sql_query($sql);

		while ($row = $this->db->sql_fetchrow($result))
		{
			$resulting_user_ids[] = $row['user_id'];

			if (!$row['notify'] || (isset($options['ignore_users'][$row['user_id']]) && in_array($row['method'], $options['ignore_users'][$row['user_id']])))
			{
				continue;
			}

			if (!isset($rowset[$row['user_id']]))
			{
				$rowset[$row['user_id']] = array();
			}

			$rowset[$row['user_id']][] = $row['method'];
		}

		$this->db->sql_freeresult($result);

		foreach ($user_ids as $user_id)
		{
			if (!in_array($user_id, $resulting_user_ids) && !isset($options['ignore_users'][$user_id]))
			{
				// No rows at all for this user, default to ''
				$rowset[$user_id] = array('');
			}
		}

		return $rowset;
	}

	/**
	* Mark this item read/unread helper
	*
	* @param bool $unread Unread (True/False) (Default: False)
	* @param bool $return True to return a string containing the SQL code to update this item, False to execute it (Default: False)
	* @return string|null If $return is False, nothing will be returned, else the sql code to update this item
	*/
	protected function mark($unread = true, $return = false)
	{
		$this->notification_read = (bool) !$unread;

		$where = array(
			'notification_type_id = ' . (int) $this->notification_type_id,
			'item_id = ' . (int) $this->item_id,
			'user_id = ' . (int) $this->user_id,
		);
		$where = implode(' AND ', $where);

		if ($return)
		{
			return $where;
		}

		$sql = 'UPDATE ' . $this->notifications_table . '
			SET notification_read = ' . (int) $this->notification_read . '
			WHERE ' . $where;
		$this->db->sql_query($sql);
	}

	/**
	 * Get a list of users that are authorised to receive notifications
	 *
	 * @param array $users Array of users that have subscribed to a notification
	 * @param int $forum_id Forum ID of the forum
	 * @param array $options Array of notification options
	 * @param bool $sort Whether the users array should be sorted. Default: false
	 * @return array Array of users that are authorised recipients
	 */
	protected function get_authorised_recipients($users, $forum_id, $options, $sort = false)
	{
		if (empty($users))
		{
			return array();
		}

		$users = array_unique($users);

		if ($sort)
		{
			sort($users);
		}

		$auth_read = $this->auth->acl_get_list($users, 'f_read', $forum_id);

		if (empty($auth_read))
		{
			return array();
		}

		return $this->check_user_notification_options($auth_read[$forum_id]['f_read'], $options);
	}
}

User avatar
kinerity
Registered User
Posts: 1102
Joined: Mon Sep 01, 2014 1:00 am
Name: Kailey Truscott
Contact:

Re: [3.2][RC] Knowledge Base

Post by kinerity » Mon Apr 17, 2017 5:10 pm

Try replacing the file with a fresh copy from the 3.2 download. The service is defined the exact same way as the board rules extension, so I know it's right.
Image

Locked

Return to “Extensions in Development”

Who is online

Users browsing this forum: Galixte de EzCom, rohde, VSE and 26 guests

cron