More compatibility for old PHP versions