added pg and rails factor