Problem in Raycast when Gameobject collides

Hi!I’m creating a game like TempleRun and I have this First Person Controller in my scene, where it has a a terrain hugging code and a collision code for collecting pickups.

My problem is, every time I collided with the pickups, my first person controller raycasting in the pickups that’s causes my FPS to slant. (see the pic where there are blue drawline of raycast)

Here is my code for terrain hugging.

void terrain_hug()
    {
       RaycastHit hitA;
       if(Physics.Raycast(transform.position + transform.forward, -transform.up, out hitA))
       {
    	RaycastHit hitB;
    	if (Physics.Raycast(transform.position - transform.forward, -transform.up, out hitB))
    	{
    	transform.forward = (hitA.point - hitB.point) *  Time.deltaTime;
    	}
       }
    }

What are you using Raycast for? Are you using Raycast to pickup objects? If so, try making the Trigger/Collider of the object a little larger than the Original object.

add rigidbody to character and set collision detection to continous.