Instantiate camera error

Hello, I was able to make a connection, still when I Instantiate the player

void SpawnPlayer(){
		Network.Instantiate(PlayerPrefab,spawnObject.position, Quaternion.identity,0);
	}

I get a second camera on the scene (each player has its own camera on the prefab).
Everything works perfect when there is only 1 player but when the second player logs in the camera follows the wrong player (both cameras) so its like you control the other player but your camera stays there.

(I have only tested this with 2 players)

Sorry about asking, a little more research did the job
I took my main camera out and did a code with this

function OnNetworkInstantiate(info : NetworkMessageInfo){

    if(networkView.isMine){

        Camera.main.GetComponent(SmoothFollow).target = transform;

    }
}

Since the only part of my game that has JS is the SmoothFollow I had to make a JS code with only this (JS starts AFTER CS)