ewallah / moodle-availability_relativedate

Relative dates in Moodle
https://moodle.org/plugins/availability_relativedate
GNU General Public License v3.0
8 stars 7 forks source link

string api usage #3

Closed ak4t0sh closed 5 years ago

ak4t0sh commented 5 years ago

https://github.com/ewallah/moodle-availability_relativedate/blob/cfa325b5b4a611a7da4225dd9f6334f1fc330528/classes/condition.php#L158 you should use core_text::strtolower see : https://docs.moodle.org/dev/String_API#strtolower

same for substr: https://github.com/ewallah/moodle-availability_relativedate/blob/cfa325b5b4a611a7da4225dd9f6334f1fc330528/classes/condition.php#L146

ewallah commented 5 years ago

fixed

danowar2k commented 4 years ago

Why should strtolower be used anyway?

EDIT: Why force the string to only contain lower chars?