From 9f3484f4c18ceab333a909a5e46641c1b842f062 Mon Sep 17 00:00:00 2001
From: Erick Hitter <git-contrib@ethitter.com>
Date: Sat, 13 Apr 2019 21:53:10 -0700
Subject: [PATCH] Bump WP compat

---
 README.md                          |  62 ++++++++++++++++
 languages/wp-revisions-control.pot | 113 +++++++++++++++++++++++++++++
 readme.txt                         |   2 +-
 wp-revisions-control.php           |   4 +-
 4 files changed, 178 insertions(+), 3 deletions(-)
 create mode 100644 README.md
 create mode 100644 languages/wp-revisions-control.pot

diff --git a/README.md b/README.md
new file mode 100644
index 0000000..38832a9
--- /dev/null
+++ b/README.md
@@ -0,0 +1,62 @@
+# WP Revisions Control #
+**Contributors:** ethitter  
+**Donate link:** https://ethitter.com/donate/  
+**Tags:** revision, revisions, admin  
+**Requires at least:** 3.6  
+**Tested up to:** 5.2  
+**Stable tag:** 1.2.1  
+**License:** GPLv2 or later  
+**License URI:** http://www.gnu.org/licenses/gpl-2.0.html  
+
+Control how many revisions are stored for each post type.
+
+## Description ##
+
+WordPress 3.6 allows users to control how many revisions are stored for each supported post type. No longer must you rely on the `WP_POST_REVISIONS` constant, which applied universally. This plugin provides an interface for this new functionality.
+
+With this plugin enabled, simply visit **Settings > Writing** to specify the number of revisions retained for each post type.
+
+Why is this helpful? Revisions are stored in the database, and if many are stored, can cause bloat. This bloat may lead to slower queries, which can have a noticeable performance impact. The value of these revisions also depends on what is being tracked. For example, I may want to store every revision of the posts I write, but only desire to keep the latest five versions of each page on my site. Starting in WordPress 3.6, this control is available. WordPress doesn’t provide a native interface to specify revisions quantities, so I wrote this quick plugin to do so.
+
+Thanks to Maria Ramos at [WebHostingHub](http://www.webhostinghub.com/), the plugin is also available in Spanish. Many thanks to her for her efforts!
+
+**Development is over on GitHub: https://github.com/ethitter/WP-Revisions-Control.**
+
+## Installation ##
+
+1. Upload wp-revisions-control to /wp-content/plugins/.
+2. Activate plugin through the WordPress Plugins menu.
+3. Go to **Settings > Writing** and set the options under **WP Revisions Control**.
+
+## Frequently Asked Questions ##
+
+### Where do I change the plugin's settings? ###
+Navigate to **Settings > Writing** in your WordPress Dashboard, and look for the **WP Revisions Control** section.
+
+## Changelog ##
+
+### 1.2.1 ###
+* Introduce Spanish translation thanks to Maria Ramos at [WebHostingHub](http://www.webhostinghub.com/).
+
+### 1.2 ###
+* Add post-level revision purging and limiting. For any post type that supports revisions, you can now limit the number of revisions retained at a post level.
+
+### 1.0 ###
+* Initial public release
+
+## Upgrade Notice ##
+
+### 1.2.1 ###
+Introduces Spanish translation thanks to Maria Ramos at [WebHostingHub](http://www.webhostinghub.com/).
+
+### 1.2 ###
+For any post type that supports revisions, you can now limit the number of revisions retained at a post level.
+
+## Screenshots ##
+
+### 1. The plugin's settings section, found under **Settings > Writing**. ###
+![The plugin's settings section, found under **Settings > Writing**.](http://ps.w.org/wp-revisions-control/assets/screenshot-1.png)
+
+### 2. The post-level controls provided in version 1.2. ###
+![The post-level controls provided in version 1.2.](http://ps.w.org/wp-revisions-control/assets/screenshot-2.png)
+
diff --git a/languages/wp-revisions-control.pot b/languages/wp-revisions-control.pot
new file mode 100644
index 0000000..d271808
--- /dev/null
+++ b/languages/wp-revisions-control.pot
@@ -0,0 +1,113 @@
+# Copyright (C) 2019 Erick Hitter
+# This file is distributed under the same license as the WP Revisions Control package.
+msgid ""
+msgstr ""
+"Project-Id-Version: WP Revisions Control 1.2.1\n"
+"Report-Msgid-Bugs-To: "
+"https://wordpress.org/support/plugin/wp-revisions-control\n"
+"POT-Creation-Date: 2019-04-14 04:52:10+00:00\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"PO-Revision-Date: 2019-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"X-Generator: grunt-wp-i18n 0.5.4\n"
+"X-Poedit-KeywordsList: "
+"__;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;_nx_noop:1,2,3c;esc_"
+"attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;esc_html_x:1,2c;\n"
+"Language: en\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"X-Poedit-Country: United States\n"
+"X-Poedit-SourceCharset: UTF-8\n"
+"X-Poedit-Basepath: ../\n"
+"X-Poedit-SearchPath-0: .\n"
+"X-Poedit-Bookmarks: \n"
+"X-Textdomain-Support: yes\n"
+
+#: wp-revisions-control.php:148
+msgid ""
+"Set the number of revisions to save for each post type listed. To retain "
+"all revisions for a given post type, leave the field empty."
+msgstr ""
+
+#: wp-revisions-control.php:149
+msgid "If a post type isn't listed, revisions are not enabled for that post type."
+msgstr ""
+
+#: wp-revisions-control.php:155
+msgid ""
+"A local change is causing this plugin's functionality to run at a priority "
+"other than the default. If you experience difficulties with the plugin, "
+"please unhook any functions from the %s filter."
+msgstr ""
+
+#: wp-revisions-control.php:274
+msgid "Revisions"
+msgstr ""
+
+#: wp-revisions-control.php:282
+msgid "Processing&hellip;"
+msgstr ""
+
+#: wp-revisions-control.php:283
+msgid "Are you sure you want to remove revisions from this post?"
+msgstr ""
+
+#: wp-revisions-control.php:284
+msgid "Autosave"
+msgstr ""
+
+#: wp-revisions-control.php:285
+msgid "There are no revisions to remove."
+msgstr ""
+
+#: wp-revisions-control.php:286
+msgid "An error occurred. Please refresh the page and try again."
+msgstr ""
+
+#: wp-revisions-control.php:312
+msgid "Purge these revisions"
+msgstr ""
+
+#: wp-revisions-control.php:315
+msgid ""
+"Limit this post to %s revisions. Leave this field blank for default "
+"behavior."
+msgstr ""
+
+#: wp-revisions-control.php:341
+msgid "No post ID was provided. Please refresh the page and try again."
+msgstr ""
+
+#: wp-revisions-control.php:343
+msgid "Invalid request. Please refresh the page and try again."
+msgstr ""
+
+#: wp-revisions-control.php:345
+msgid "You are not allowed to edit this post."
+msgstr ""
+
+#: wp-revisions-control.php:357
+msgid "Removed %s revisions associated with this post."
+msgstr ""
+
+#. Plugin Name of the plugin/theme
+msgid "WP Revisions Control"
+msgstr ""
+
+#. Plugin URI of the plugin/theme
+msgid "https://ethitter.com/plugins/wp-revisions-control/"
+msgstr ""
+
+#. Description of the plugin/theme
+msgid "Control how many revisions are stored for each post type"
+msgstr ""
+
+#. Author of the plugin/theme
+msgid "Erick Hitter"
+msgstr ""
+
+#. Author URI of the plugin/theme
+msgid "https://ethitter.com/"
+msgstr ""
\ No newline at end of file
diff --git a/readme.txt b/readme.txt
index 7f20d1b..df46245 100644
--- a/readme.txt
+++ b/readme.txt
@@ -3,7 +3,7 @@ Contributors: ethitter
 Donate link: https://ethitter.com/donate/
 Tags: revision, revisions, admin
 Requires at least: 3.6
-Tested up to: 4.6
+Tested up to: 5.2
 Stable tag: 1.2.1
 License: GPLv2 or later
 License URI: http://www.gnu.org/licenses/gpl-2.0.html
diff --git a/wp-revisions-control.php b/wp-revisions-control.php
index 8eee165..4049892 100644
--- a/wp-revisions-control.php
+++ b/wp-revisions-control.php
@@ -271,7 +271,7 @@ class WP_Revisions_Control {
 		if ( post_type_supports( $post_type, 'revisions' ) && 'auto-draft' != get_post_status() && count( wp_get_post_revisions( $post ) ) > 1 ) {
 			// Replace the metabox
 			remove_meta_box( 'revisionsdiv', null, 'normal' );
-			add_meta_box( 'revisionsdiv-wp-rev-ctl', __('Revisions'), array( $this, 'revisions_meta_box' ), null, 'normal', 'core' );
+			add_meta_box( 'revisionsdiv-wp-rev-ctl', __('Revisions', 'wp_revisions_control'), array( $this, 'revisions_meta_box' ), null, 'normal', 'core' );
 
 			// A bit of JS for us
 			$handle = 'wp-revisions-control-post';
@@ -281,7 +281,7 @@ class WP_Revisions_Control {
 				'action_base'     => $this->settings_section,
 				'processing_text' => __( 'Processing&hellip;', 'wp_revisions_control' ),
 				'ays'             => __( 'Are you sure you want to remove revisions from this post?', 'wp_revisions_control' ),
-				'autosave'        => __( 'Autosave' ),
+				'autosave'        => __( 'Autosave', 'wp_revisions_control' ),
 				'nothing_text'    => wpautop( __( 'There are no revisions to remove.', 'wp_revisions_control' ) ),
 				'error'           => __( 'An error occurred. Please refresh the page and try again.', 'wp_revisions_control' )
 			) );
-- 
GitLab