subsys/shell: check for shell context before accessing it

The ASSERT order is backwards, where the shell->ctx is being accessed
before it is being checked as valid.  Moving the check for the
shell->ctx to before the using it.

Signed-off-by: Dan Kalowsky <dkalowsky@amperecomputing.com>
1 file changed