Symbolics with Control Flow

I’m trying to create a function with if condition using a symbolic var:

using Symbolics
@variables t
params = @parameters F

function f(t)
	if 0≤t<5
        return 1

	if 5≤t<10
        return -1
	return 0

Q = [F*f(t), 0]

The error is at `Q = [F*f(t), 0]’ :

ERROR: TypeError: non-boolean (Num) used in boolean context

How can I overcome this error?
thanks in ahead.

Frequently Asked Questions · ModelingToolkit.jl? - " How do I handle if statements in my symbolic forms?"

thank you very much, that solved my issue.