Skip to content

Bug: Call to undefined function CodeIgniter\Shield\Controllers\emailer()  #506

@Kimotu

Description

@Kimotu

PHP Version

7.4.6

CodeIgniter4 Version

4.2.8

Shield Version

1.0.0-beta.3

Which operating systems have you tested for this bug?

Linux

Which server did you use?

fpm-fcgi

Database

MariaDB

Did you customize Shield?

No.

No inherited classes, just own views.

What happened?

I upgraded to shield-1.0.0-beta3 (composer upgrade), checked new user creation with mail verification and got Call to undefined function CodeIgniter\Shield\Controllers\emailer() .

I looked through the code. Three classes use emailer()

  • MagicLinkController.php
  • Email2FA.php
  • EmailActivator.php

When I add helper('email') before each of the three emailer() calls, everything works as before.

Steps to Reproduce

Upgrade to latest shield via composer and try a function that uses mails.

Expected Output

activation mail, 2FA or magic link mail sent

Anything else?

Was there a helper call in previous version or is something wrong in autoloading the helper class?

Metadata

Metadata

Assignees

No one assigned

    Labels

    waiting for infoIssues or pull requests that need further clarification from the author

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions