migrated to postgresql and added facebook login