Skip to content

Commit aede182

Browse files
authored
Merge pull request #130 from VSEphpbb/maintenance
Some general maintenance
2 parents b1a112c + deee005 commit aede182

5 files changed

Lines changed: 10 additions & 100 deletions

File tree

.editorconfig

Lines changed: 0 additions & 16 deletions
This file was deleted.

adm/style/acp_phpbb_ideas.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ <h3>{{ lang('WARNING') }}</h3>
1313
</div>
1414
{% endif %}
1515

16-
<form id="acp_phpbb_ideas_settings" method="post" action="{{ U_ACTION }}">
16+
<form id="acp_phpbb_ideas_settings" method="post" action="{{ U_ACTION }}" data-ajax="true">
1717
<fieldset>
1818
<legend>{{ lang('ACP_PHPBB_IDEAS_SETTINGS') }}</legend>
1919
<dl>

ext.php

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,21 @@ class ext extends \phpbb\extension\base
2222
{
2323
/**
2424
* Check whether or not the extension can be enabled.
25-
* The current phpBB version should meet or exceed
26-
* the minimum version required by this extension:
2725
*
28-
* Requires phpBB 3.2.1 due to use of $event->update_subarray()
26+
* Requires phpBB >= 3.2.1 due to use of $event->update_subarray()
27+
* Also incompatible with SQLite which does not support SQRT in SQL queries
2928
*
3029
* @return bool
3130
* @access public
3231
*/
3332
public function is_enableable()
3433
{
35-
return phpbb_version_compare(PHPBB_VERSION, '3.2.1', '>=');
34+
if (phpbb_version_compare(PHPBB_VERSION, '3.2.1', '<'))
35+
{
36+
return false;
37+
}
38+
39+
$db = $this->container->get('dbal.conn');
40+
return ($db->get_sql_layer() !== 'sqlite3');
3641
}
3742
}

factory/ideas.php

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -749,20 +749,6 @@ public function submit($data)
749749
return $idea_id;
750750
}
751751

752-
/**
753-
* Preview a new idea.
754-
*
755-
* @param string $message The description of the idea.
756-
*
757-
* @return string The idea parsed for display in preview.
758-
*/
759-
public function preview($message)
760-
{
761-
$uid = $bitfield = $flags = '';
762-
generate_text_for_storage($message, $uid, $bitfield, $flags, true, true, true);
763-
return generate_text_for_display($message, $uid, $bitfield, $flags);
764-
}
765-
766752
/**
767753
* Deletes an idea and the topic to go with it.
768754
*

tests/ideas/preview_idea_test.php

Lines changed: 0 additions & 65 deletions
This file was deleted.

0 commit comments

Comments
 (0)