Does black-hole growth depend on the cosmic environment?