@madmoo101,
It's not that simple.
Some Californians wanted California to be a slave state. This was what is sometimes called the Second Missouri Compromise although it had nothing to do with the state of Missouri which had already joined the Union in 1820. Missouri was admitted as a slave state and Maine, previously a part of Massachusetts, was split off as a new free state. The idea, of course, was to keep a balance between free and slave states. In the case of Calfornnia, it was admitted as a free state (in 1850) while Texas was allowed to join at the same time as a slave state.
That's off the top of my head but you can look it up in Wikipedia and elsewhere.