On Thursday, Texas Gov. Greg Abbott signed the state's Sandra Bland Act, named after the black woman who was found dead in a Waller County jail cell, into law.

Bland's case was a controversial one. In 2015, she was pulled over by a state trooper, and what should have been a routine stop quickly escalated into a violent encounter. The officer, who was later fired for violating protocol, said Bland became uncooperative. She was arrested and jailed, and her death was ruled a suicide. It was later revealed that Bland might have suffered from depression and had a history of mental health issues.

The state's new law requires jailers to immediately determine whether inmates suffer from mental illness and divert those who do to a mental health facility. That's what should have happened to Bland, and that action could very well have saved her life.

Don't warehouse the mentally ill

Americans tend to think of mental health as an issue at the margins of society. But 46% of the deaths of unarmed civilians after a police encounter involved someone suffering from serious mental illness, overdosing on drugs or both. And jailing a mentally ill inmate costs $31,000 annually, while community mental health services cost about $10,000, according to the National Alliance on Mental Illness.

Consider this story from North Texas: A man with a mental health condition reported more than 120 times in 18 months that his neighbor was hammering on the side of his house in the middle of the night. Security cameras installed at the suggestion of a frustrated patrol officer caught no one, but the man’s hallucinations continued. After his neighbors sold their house, the man insisted that the hammering continued. Desperate for relief, he attacked his new neighbors. Only after he attacked someone was he finally detained and transported for an emergency psychiatric evaluation.

Putting a man like him in jail costs more and does neither him nor the community any good. The mental health provisions of the Sandra Bland Act ensure earlier mental health evaluations (by police officers on the ground) and make sure that jail isn’t the first and only option. The law will also ensure that officers have de-escalation training, that jail cells are properly inspected and that jail deaths are independently investigated.

In Texas, several law enforcement departments already provide officers with training and experience in proactively addressing mental health issues before a crisis occurs. This involves both Crisis Intervention Teams and training to recognize mental health issues.

Screening and diversion saved $10 million a year in San Antonio. In Miami, similar reforms saved $12 million and reduced the number of jail inmates by 38%.

Another program in North Texas focuses on wellness checks, with trained mental health professionals riding with cops. Those cities have seen a reduction in acute mental health crisis hospitalizations and fewer people jailed. But a statewide mandate from a state as big — and conservative — as Texas can move the needle and inspire national change.

Some are surprised that Texas is so proactive on this issue. While Texas admittedly has some regressive policies, it is a leader in issues around open records and police reform.

No longer will Texas jails serve as ineffective warehouses for people with mental health conditions.

Forcing accountability in mental health industry

Whether Texas' mental health system has the capacity to handle a major influx of new patients is a troubling, unanswered question. Once it adapts, however, Texas will lock up fewer people for whom jail is a wholly inappropriate measure.

The law also will pull back a curtain that has hidden people with mental health conditions from state officials and lawmakers. When Texans see the numbers, they and other states will have to acknowledge the need for more appropriate resources.

The first challenge of implementation will be getting cops to change their culture. Police want to catch bad guys, not answer calls about or from people in mental health crisis, where they wind up in frustrating situations they don’t always know how to respond to. Officers must view people with mental health conditions as people in need of help, not just criminals and threats.

When officers have training and work collaboratively with mental health service providers, everyone wins — people with mental health conditions receive the help they need, officers are freed up to catch bad guys, and taxpayers know their dollars are spent wisely.

Nick Selby is a Dallas-area police detective, and was lead author of In Context: Understanding Police Killings of Unarmed Civilians. Colt Remington is a certified Texas Mental Health Peace Officer. A former U.S. Marine, Remington patrols, and instructs other officers on mental health issues, at a large agency in the DFW Metroplex.