From 24e76a1d9dd432da3986d382f5ec35e74a1157d3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Mar=C3=ADa=20Fernanda=20Magallanes?=
<35668326+MaferMazu@users.noreply.github.com>
Date: Wed, 13 Dec 2023 13:11:07 -0400
Subject: [PATCH] refactor: improve double dirname and add more documentation
of Open edX (#64)
* refactor: improve the double dirname
* docs: add more information about the Open edX connection and fix the tested up version
---
README.md | 8 ++++++++
README.txt | 10 +++++++++-
includes/class-openedx-commerce-i18n.php | 2 +-
3 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 78d1d98..784deef 100644
--- a/README.md
+++ b/README.md
@@ -23,6 +23,14 @@ Here are some things you can do with this plugin:
- **Obtain enrollment information:** This requests the Open edX APIs to retrieve the enrollment status of a user in a course.
+**Note**
+
+This plugin calls the APIs from Open edX Platform.
+
+More information about the API connection can be found in Decisions: API connection.
+
+To learn more, you can visit the Open edX Terms of Service.
+
# Installation
## Requirements
diff --git a/README.txt b/README.txt
index 626e282..72ae274 100644
--- a/README.txt
+++ b/README.txt
@@ -2,7 +2,7 @@
Contributors: felipemontoya, julianrg2, mafermazu
Tags: openedx, open edx, ecommerce, lms, courses
Requires at least: 6.3
-Tested up to: 6.3.1
+Tested up to: 6.3
Requires PHP: 8.0
Stable tag: 2.0.1
License: GPLv2 or later
@@ -41,6 +41,14 @@ Below are some links to help you get started with Open edX WooCommerce Plugin:
- Quick Start Guide
- How-to Guides
+**Note**
+
+This plugin calls the APIs from Open edX Platform.
+
+More information about the API connection can be found in Decisions: API connection.
+
+To learn more, you can visit the Open edX Terms of Service.
+
== Installation ==
= Minimum Requirements =
diff --git a/includes/class-openedx-commerce-i18n.php b/includes/class-openedx-commerce-i18n.php
index 40bca34..545aaee 100644
--- a/includes/class-openedx-commerce-i18n.php
+++ b/includes/class-openedx-commerce-i18n.php
@@ -38,7 +38,7 @@ public function load_plugin_textdomain() {
load_plugin_textdomain(
'openedx-commerce',
false,
- dirname( dirname( plugin_basename( __FILE__ ) ) ) . '/languages/'
+ dirname( plugin_basename( __FILE__ ), 2 ) . '/languages/'
);
}
}