@throws remove namespace and create use statement

Prior to Wednesday 2022-05-11, if I used the `Add @throws tag` option when pressing Alt+Enter, it would add them but then give me additional Alt+Enter options to remove their namespace and ensure that a `use` statement was added to the top of the file.  On that day, rather than using that command (I thought it started with the word "cleanup" but searching the settings didn't help me find it), I must have accidentally disabled it.  Now, @throws information is generated with the fully namespaced Exceptions that are being thrown, but I can't, with one click, clean them up.

Anyone know what I turned off?  Even after only two days, it's driving me quite batty to fix them by hand.

Thanks,
Dash

3 comments
Comment actions Permalink

Oh!  Worse:  if I use the `Update PHPDoc Comment` command, it'll switch the @throws lines back to their fully namespaced syntax and I have to fix them again.  This was definitely something I changed in the app settings; there've been no updates for me in the last few days.

Thanks again,
Dash

0
Comment actions Permalink

Hi there,

Oh!  Worse:  if I use the `Update PHPDoc Comment` command, it'll switch the @throws lines back to their fully namespaced syntax and I have to fix them again.

Please check: "Settings (Preferences on macOS) | Editor | Code Style | PHP | PHPDoc | Generated PHPDoc tags | Use fully-qualified class names"

 

if I used the `Add @throws tag` option when pressing Alt+Enter, it would add them but then give me additional Alt+Enter options to remove their namespace and ensure that a `use` statement was added to the top of the file

Not super sure, but please check PHP section at "Settings (Preferences on macOS) | Editor | General | Auto Import"

If nothing -- please also check "Settings (Preferences on macOS) | Editor | Intentions | PHP" -- maybe it's one of them.

 

1
Comment actions Permalink

It was the first one, the Use full-qualified class names setting.  Thanks!  I was focused on the list of intentions and couldn't find one that seemed to have changed.

Thanks!!

0

Please sign in to leave a comment.