Skip to content

Commit 7d504de

Browse files
committed
[docs] max sections deprecation
1 parent d8660fa commit 7d504de

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

docs/apis/plugintypes/format/index.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,6 @@ You must define `$string['sectionname']` if your language file even if the forma
206206
| `get_section_number()` | Return zero if the course will deploy all sections or a section number if the current page is only presenting a single section. |
207207
| `get_course_display()` | Return `COURSE_DISPLAY_SINGLEPAGE` or `COURSE_DISPLAY_MULTIPAGE` depending if the course has multiple section per page or not. |
208208
| `get_last_section_number()` | Returns the last section |
209-
| `get_max_sections()` | Returns the maximum number of sections this format can contain |
210209
| `page_title()` | Formats can override this method to alter the page title. |
211210

212211
### Course features

docs/devupdate.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,12 @@ tags:
88
<!-- markdownlint-disable no-inline-html -->
99

1010
This page highlights the important changes that are coming in Moodle 5.1 for developers.
11+
12+
## Course format: max sections setting is now deprecated
13+
14+
<Since version="5.1" issueNumber="MDL-84291" />
15+
The `maxsections` setting in course formats is now deprecated. Previously, this setting was used to limit the number of sections in a course. Starting with Moodle 5.1, courses can have an unlimited number of sections.
16+
17+
Although the `maxsections` setting remains available for now, it is marked as deprecated and will be removed in Moodle 6.0. Also, the `get_max_sections` from `core_courseformat\base` is also deprecated and will be removed in Moodle 6.0.
18+
19+
If your format plugin relies on `maxsections`, you should add a custom setting in your plugin to control section limits. For reference, see the week format plugin, which now uses its own setting for this functionality.

0 commit comments

Comments
 (0)