Sound playing from headphones and speakers

The sound is playing from my speakers and headphones, In Linux Mint I used HDAjackretask to fix this issue but it doesn’t appear to be available for Arch.

Have you check in alsamixer if “Auto-Mute Mode” is enabled? By the way, hdajackretask is in the alsa-tools package.

There is no “Auto-Mute Mode” listed in alsamixer.
Tried to install alsa-tools via Pamac but got errors.

Preparing…
Synchronizing package databases…
Refreshing core.db…
Downloading core.db. (core.db.si)…
Error: core.db.sig: GPGME error: No data
invalid or corrupted database (PGP signature)
Refreshing community.db…
Failed to prepare transaction:
invalid or corrupted database
Failed to prepare transaction:
invalid or corrupted database

When you opened it, did you press F6 and select the right card?

Try running sudo pacman-mirrors -f 5, and then sudo pacman -Syu.

Got this command from a previous manjaro post sudo pacman-mirrors -f && sudo pacman -Syu and it fixed the database errors.
Also ran sudo pacman-key --refresh-keys

When you opened it, did you press F6 and select the right card?

Yes I did

Got alsa-tools installed and fixed my problem with hdajackretask