  We prove that, if $m,n\geqslant 1$ and $a_1,\ldots,a_m$ are nonnegative
integers, then \begin{align*}
\frac{[a_1+\cdots+a_m+1]!}{[a_1]!\ldots[a_m]!}\sum^{n-1}_{h=0}q^h\prod_{i=1}^m{h\brack
a_i} \equiv 0\pmod{[n]}, \end{align*} where $[n]=\frac{1-q^n}{1-q}$,
$[n]!=[n][n-1]\cdots[1]$, and ${a\brack
b}=\prod_{k=1}^b\frac{1-q^{a-k+1}}{1-q^k}$. The $a_1=\cdots=a_m$ case confirms
a recent conjecture of Z.-W. Sun. We also show that, if $p>\max\{a,b\}$ is a
prime, then \begin{align*} \frac{[a+b+1]!}{[a]![b]!}\sum_{h=0}^{p-1}q^h{h\brack
a}{h\brack b} \equiv (-1)^{a-b} q^{ab-{a\choose 2}-{b\choose
2}}[p]\pmod{[p]^2}. \end{align*}
