Problems with PlayerBindPress

I started working on a weapon selection, but I encountered problems.

I’m able to scroll through the numbers, but once I’ve selected one it disables me from continueing to scroll through the weapons. I’ve tried numerous things to fix it, but with no result. If any of you’d be able to spot the problem, it’d be more than gladly appreciated.
[lua]
function GM:PlayerBindPress( ply, bind, down )

if( ( bind == "+attack2" or bind == "+attack" ) ) then

	if( WeaponList[CurrentSlotPos] ) then
	
		LocalPlayer():ConCommand( "rp_selectweapon " .. WeaponList[CurrentSlotPos] .. "

" );

		WeaponMenuPress = true;
		
		return true;
	
	end
	
end

if( not WeaponMenuPress and not LocalPlayer():KeyDown( IN_ATTACK ) and not LocalPlayer():KeyDown( IN_ATTACK2 ) ) then

	if( bind == "invnext" ) then
	
		if( CurrentSlotPos >= #WeaponList ) then
		
			CurrentSlotPos = #WeaponList;
		
		else
		
			CurrentSlotPos = CurrentSlotPos + 1;
		
		end
	
	end
	
	if( bind == "invprev" ) then
	
		if( CurrentSlotPos <= 1 ) then
		
			CurrentSlotPos = 1;
		
		else
		
			CurrentSlotPos = CurrentSlotPos - 1;
		
		end
	
	end

end

end[/lua]
Thank you in advance.